SourceForge has been redesigned. Learn more.
Close

#65 CPP-Version: codegen bug for CALL USING LOCAL-STORAGE items with sub-items

GC++ 2.0
closed
None
6
2014-11-24
2014-02-06
No

Bug in CPP only.

The following program results in not compilable C++ source (compiled with -m):

       IDENTIFICATION   DIVISION.
       PROGRAM-ID.      callee.
       DATA             DIVISION.
       WORKING-STORAGE  SECTION.
       01 WRK-X         PIC XXX VALUE "abc".
       LOCAL-STORAGE    SECTION.
       01 LCL-X.
          05 FILLER     PIC XXX VALUE "abc".
       PROCEDURE        DIVISION.
           CALL "callee2" USING LCL-X
           END-CALL.
           EXIT PROGRAM.

See test [LOCAL-STORAGE (2)] - see run_misc.at (test added [with expected failure in CPP version] in [r205]):

/tmp/cob948_0.cpp: In function 'int callee_(int)':
/tmp/cob948_0.cpp:100: error: invalid lvalue in unary '&'
/tmp/cob948_0.cpp:105: error: invalid lvalue in unary '&'
/tmp/cob948_0.cpp:109: error: invalid lvalue in unary '&'
/tmp/cob948_0.cpp:113: error: invalid lvalue in unary '&'
/tmp/cob948_0.cpp:118: error: invalid lvalue in unary '&'

Simon

Related

Commit: [r205]

Discussion

  • Simon Sobisch

    Simon Sobisch - 2014-02-07
    • status: accepted --> closed
     
  • Simon Sobisch

    Simon Sobisch - 2014-02-07

    Fixed with [r210]

     

    Related

    Commit: [r210]

  • Simon Sobisch

    Simon Sobisch - 2014-11-24
    • Group: unclassified --> GC++ 2.0
     

Log in to post a comment.