uwol / proleap-vb6-parser

ProLeap ANTLR4-based parser for Visual Basic 6.0
MIT License
79 stars 26 forks source link

Optional Argument #16

Closed kaoecoito closed 6 years ago

kaoecoito commented 6 years ago

Hello, In the sample call below

MetodoCall Param1, , Param2

The ArgsCallContext returns 2 arguments and 2 commas. With the 2 commas I detect that there are 3 parameters, but the order of them is not detectable. Is there an example of how to detect the second null parameter?

kaoecoito commented 6 years ago

Hello, To get registered, my solution was to scan all the children of ArgsCallContext by checking whether they would be instances of TerminalNode (comma) or ArgCallContext. In this way it worked correctly. Thank you.

uwol commented 6 years ago

OK, thanks for the info! I'll have to check, whether this could become part of the ASG, as it is a relevant information.