Unconfigured Ad Widget

Collapse

Announcement

Collapse
No announcement yet.

Moving to Free-Format in RPG IV via WDSC

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Moving to Free-Format in RPG IV via WDSC

    ** This thread discusses the article: Moving to Free-Format in RPG IV via WDSC **
    ** This thread discusses the Content article: Moving to Free-Format in RPG IV via WDSC **
    0

  • #2
    Moving to Free-Format in RPG IV via WDSC

    ** This thread discusses the article: Moving to Free-Format in RPG IV via WDSC **
    Free-Format simply opens up a pandora's box of illegible unmaintainable code in the genre of C. We struggle enough in ILE RPG to have agreed upon standards of coding so that some semblence of maintainability exists. With Free-Format there exist, by definition, no standards. That being said... Recently I had need of the UpDate op code with the %fields built in function. Yes, I could have done an Except with only one output field but I desired to use the UpDate. Thus, out of necessity, I used a /Free - /End-Free code segment. Conclusion: Out of Necessity - yes, use Free-Format. In all other cases: I'm with Janis Joplin Freedom(Free-Format) is just another word for nothin' left to lose. Thank-you KgOleMn

    Comment


    • #3
      Moving to Free-Format in RPG IV via WDSC

      ** This thread discusses the article: Moving to Free-Format in RPG IV via WDSC **
      Bob, What is hybrid/native RPGIV? Thanks. Tom.

      Comment


      • #4
        Moving to Free-Format in RPG IV via WDSC

        ** This thread discusses the article: Moving to Free-Format in RPG IV via WDSC **
        I really don't understand your statement about free-format and illegible code. Quite frankly, I think free-format gives us the very thing we need to increase the readability of our code. That would be indenting. No more need for RPG-Alive, or a quick compile and print to diagnose nesting errors and missing end opcodes. Standards play a huge role in defining the structure of free-format code. You are absolutely correct, with free there are no standards.... UNTIL YOU CREATE THEM!!!!! Someone created the standards that you apply to columnar RPG. Perhaps you can be the one that develops the standards for free-form RPG. Once a style is defined, then its important for everyone in the shop to try to comply. Any style or formatting issues should be identified in peer review and corrections made before implementation. The process enforces the standards. As to bad style, I've seen plenty of it over the years in all flavors of RPG. Some was even mine.... However, I learned what was effective and what was not, and forced myself to avoid the latter whenever possible.... How is the transition to Free-format any different. I highly recommend that you read Code Complete by Steve McConnell. Even though this is published by Microsoft Press, it is not about any Microsoft products, but is all about best practice in programming. JMO, Eric DeLong

        Comment


        • #5
          Moving to Free-Format in RPG IV via WDSC

          ** This thread discusses the article: Moving to Free-Format in RPG IV via WDSC **
          I feel the code is only illegible because the person coding didn't take the time to make it legible. Commenting, program structure, field naming etc. are almost identical between free format and RPG IV. If the person coding doesn't include comments, and uses field names like xr1# than the code is illegible in both RPG IV and free format. I prefer free format and I'm lucky in that I'm the only programmer here so I don't have debate which style to use here. I also think free format is more intuitive simply because of indentation. But someone who has been working with column formatted text for a long time is probably really good at digging through nested If statements and doesn't care about indentation. I would advise never to use Free Format and Fixed Column RPG together. It's hideous.

          Comment


          • #6
            Moving to Free-Format in RPG IV via WDSC

            ** This thread discusses the article: Moving to Free-Format in RPG IV via WDSC **
            Notice there's no WDSC "Convert selection from free-format" to traditional RPG IV as you call it. George Farr made sure that option won't ever exist.

            Comment


            • #7
              Moving to Free-Format in RPG IV via WDSC

              ** This thread discusses the article: Moving to Free-Format in RPG IV via WDSC **
              Using the Extended Factor 2 syntax, which includes opcodes such as EVAL, IF, WHEN, FOR, etc. is considered "native RPG IV" and also a hybrid between the old fixed-format and the new /free free-format syntax.

              Comment

              Working...
              X