Open BrianGodsend opened 1 year ago
Note, the moving the CALL
statement appears to be inconsistent. A trigger to make something bad happen seems to be:
CALL
PARM
statements for the CALL
, only executable C-SpecsThe odd behaviors include:
CALL
statement is moved up one lineCALL
statement is doubled (one call placed before the previous line, then the call in the proper location)CALL
have the wrong indentation.This is may be a duplicate of #6.
When a
CALL
statement is converted to **FREE format, theCALL
is converted to a procedure style call. There are a few problems:Fixed format RPG:
Wrong output:
Expected output:
If a
CALL
specifies variables in factor 1 (return values), theCALL
statement cannot be converted to FREE. There is no equivalent syntax in FREE that would support this. The closest approximation would be to set the factor 1 variable to the contents of the result field, then pass the factor 1 as the parameter. This would require adding additional lines before the call. Also additional lines would also be needed if any initialization value was being passed as well.For example, assume QCMDEXC passed back something to do with the command length, the following RPG could be used:
Fixed format RPG:
Expected output: