× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Good point on columnar definitions of D specs.  I line up my definitions 
in CL this way
DCL  &APOS        *CHAR   1  /* Apostrophe */
DCL  &PARM1       *CHAR   2  /* */
DCL  &PARM2       *DEC    2  /* */
DCL  &DATA        *CHAR  30  /* Message data from RCVMSG */
DCL  &KEYVAR      *CHAR   4  /* Message key from RCVMSG */
DCL  &MSGID       *CHAR   7  /* Message id from RCVMSG */

The hilarious thing is that people who'll give up fixed format coding in 
RPG only at gunpoint quickly prompt and change my CL to free format with 
all sorts of space tied up for keywords.  Is this really that much more 
readable?  (I chopped off all that wasted space on the left they create. 
Helps the list to not see wrapping.)
DCL        VAR(&APOS) TYPE(*CHAR) LEN(1) /* + 
             Apostrophe                               */ 
DCL        VAR(&PARM1) TYPE(*CHAR) LEN(2) + 
             /*                                          +
             */ 
DCL        VAR(&PARM2) TYPE(*DEC) LEN(2) + 
             /*                                          +
             */ 
DCL        VAR(&DATA) TYPE(*CHAR) LEN(30) /* Message + 
             data from RCVMSG                 */ 
DCL        VAR(&KEYVAR) TYPE(*CHAR) LEN(4) /* Message + 
             key from RCVMSG                  */ 
DCL        VAR(&MSGID) TYPE(*CHAR) LEN(7) /* Message id + 
             from RCVMSG                   */ 

You don't suppose fixed format D specs inhibit data structure size 
changes?  Granted, the string size is much larger now, but I can remember 
in earlier versions of RPG you couldn't fit the size of the variables 
needed into the length columns.

Rob Berendt

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.