Menu

#66 COPY REPLACING LEADING produces wrong ast

v1.0 (example)
open
nobody
None
5
2017-09-24
2017-09-24
No

When you parse a source with "COPY REPLACING LEADING" you get the following in tne AST for the included line.
<recordDescriptionEntry>
<dataDescriptionEntry>
<levelNumber>
<t><![CDATA[05]]></t>
</levelNumber>
<unknown>
<t><![CDATA[LS-STACK-POINTER]]></t>
<t><![CDATA[ ]]></t>
<t><![CDATA[PIC]]></t>
<t><![CDATA[ ]]></t>
<t><![CDATA[9]]></t>
<t><![CDATA[(]]></t>
<t><![CDATA[4]]></t>
<t><![CDATA[)]]></t>
</unknown>
<t><![CDATA[.]]></t>
</dataDescriptionEntry>
</recordDescriptionEntry>
instead of the correct
<recordDescriptionEntry>
<dataDescriptionEntry>
<levelNumber>
<t><![CDATA[05]]></t>
</levelNumber>
<t><![CDATA[ ]]></t>
<entryName>
<dataName>
<cobolWord>
<t><![CDATA[LS-STACK-POINTER]]></t>
</cobolWord>
</dataName>
</entryName>
<t><![CDATA[ ]]></t>
<pictureClause>
<t><![CDATA[PIC]]></t>
<t><![CDATA[ ]]></t>
<pictureString>
<t><![CDATA[9]]></t>
<t><![CDATA[(]]></t>
<t><![CDATA[4]]></t>
<t><![CDATA[)]]></t>
</pictureString>
</pictureClause>
<unknown/>
<t><![CDATA[.]]></t>
</dataDescriptionEntry>
</recordDescriptionEntry>

Discussion


Log in to post a comment.