79216306

Date: 2024-11-22 19:14:39
Score: 3
Natty:
Report link

I'm aware this question was asked 10 years ago (or thereabouts). But..., we're still facing this problem with Antlr 4.16 (latest version). Sufficiently deeply nested Cobol if-then-else statements with optional trailing end-if can take upto 7 minutes in the parser - from start rule... We've profiled it, and we're seeing all the time spent in the if-then -else walking. We're using the same grammar if_statement: IF condition THEN? statement_list (ELSE statement_list)? END_IF?

Any thoughts or suggestions would be welcome.

Reasons:
  • Blacklisted phrase (1.5): Any thoughts
  • Long answer (-0.5):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (1):
Posted by: Anil Peres-da-Silva