RPG, RDi Free-Format Support Reach GA

by Tim Rowe
Dec 16, 2013

Greetings! I hope you all are well. I've been off in China for the past couple of months, and I've had the wonderful opportunity to talk with many IBM i customers there. It's been fun talking to them about modernization and the future of the IBM i platform. The good news is that while I've been off working with our IBM i customers in China, the development teams have been very busy! Back in October, IBM announced a very exciting new improvement to the RPG language: free-form ...

REGISTER NOW TO ACCESS THIS ARTICLE

All registered users get access to premium content on iPro Developer for free.

Already registered? Log in here.

Discuss this Blog Entry 4

on Dec 17, 2013

I've been coding in /free for about 10 years now but I just gotta say, these new DCL- op codes are about the ugliest things I've ever seen. Is it just me?

on Jan 30, 2014

Clearly not just you - but personally I have no problem with it and I've had very little push back from those I've taught it to.

An "op-code" type approach is really the only way RPG can go for this type of thing. There are many reasons for this but most come back to the former columnar nature of the language. For example, because of the columns RPG never needed reserved words - the name READ (for example) could be an either an op-code or a variable name.

Sure there are other syntaxes that could have been used but as far as possible it needed to retain whatever syntax it could from the D and F specs. I think they did a pretty darn good job.

on Jan 21, 2014

Nope. You are not alone. In 2000-01 when /free first came in, and George Farr opened a discussion forum, I had suggested a total /free in following format:

Declare DataStructure prtDs;
customer_Code integer(7);
customer_Name varchar(25);
active_Status char default('Y");
End-Declare;

Got rejected immediately by the RPG compiler team lead with strong remarks like RPG should never be totally free cuz it would have no ROI

on Jan 30, 2014

Syntax suggestions for files? Arrays? Externally described DS? What about standalone fields, etc. etc. etc.

Your suggested syntax was OK as far as it went but it doesn't go far enough. Sounds like the response you saw came from Hans - but he's no longer around and happily they went ahead and made the update.

Please log in or register to post comments.