uwol / proleap-cobol-parser

ProLeap ANTLR4-based parser for COBOL
MIT License
136 stars 74 forks source link

call to unknown data element fort-struktur #34

Closed Reinhard-Prehofer closed 6 years ago

Reinhard-Prehofer commented 7 years ago

Not sure what really causes the parser to have problems with the data structure inside the attached cobol program. The original data structure of the customer is much more complicated, including redefines and occurs as well ...

       01  FORT-Struktur.
           05 FORT-ANZ             PIC S9(7).
           05 FORT-TAB .
             10  C1FONEU.
               15 P8000                     PIC  X(14).
               15 PG8100.
                 20 PG8028-gruppe .
                   25 P8028               PIC  9(3).
                   25 P8028-N             PIC  9(2).
                 20 P8028-S               PIC  X(3).

Parser issues the following message: call to unknown data element fort-struktur a2612ABS.CBL.txt

uwol commented 6 years ago

This was a bug, which occurred due to case-sensitive identifier resolving.

Same as in #22, fixed yesterday with a2922058cb515dbd2131061cf556c40186c6a993. However, added a unit test for the code provided in this issue.

Thanks for issuing!