Menu

#57 Incorrect XML for up/down by

v1.0 (example)
closed-fixed
nobody
None
5
2015-11-11
2015-11-10
Sean Walker
No

In NC135A from the COBOL test suite, this statement seems to get the wrong XML generated

044100     SET  INXEX2 DOWN BY  IDEN-1.                                 NC1354.2
              <sentence>
                <statement>
                  <setStatement>
                    <t><![CDATA[SET]]></t>
                    <t><![CDATA[  ]]></t>
                    <setOther>
                      <qualifiedDataName>
                        <dataName>
                          <cobolWord>
                            <t><![CDATA[INXEX2]]></t>
                          </cobolWord>
                        </dataName>
                      </qualifiedDataName>
                      <t><![CDATA[ ]]></t>
                      <t><![CDATA[DOWN]]></t>
                      <t><![CDATA[ ]]></t>
                      <t><![CDATA[BY]]></t>
                      <t><![CDATA[  ]]></t>
                      <integer>
                        <integerConstant>
                          <cobolWord>
                            <t><![CDATA[IDEN-1]]></t>
                          </cobolWord>
                        </integerConstant>
                      </integer>
                    </setOther>
                    <unknown />
                  </setStatement>
                </statement>
                <t><![CDATA[.]]></t>
              </sentence>

Basically, IDEN-1 is not an integerConstant.

It is all over NC140A as well.

Discussion

  • KrisDS

    KrisDS - 2015-11-11

    Fixed in [r309]. I changed the matching order so identifiers are not being eagerly matched as integer constants.

     

    Related

    Commit: [r309]

  • KrisDS

    KrisDS - 2015-11-11
    • status: open --> closed-fixed
     

Log in to post a comment.

MongoDB Logo MongoDB