question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Matched tokens being marked as error

See original GitHub issue

I found a case where the parser is marking matched tokens found inside error nodes as an error. For instance, given the malformed expression 1 * 2 +++, this is the resulting tree:

antlr4_parse_tree

However, it’s the expected tree:

image

Notice that the operators + are being marked as an error in the first tree, although they have being recognized as operators.

It worth noting that the former tree was generated using the TestRig, while the latter is a screenshot of the tree generated in the IntelliJ plugin. This issue is most likely related to antlr/intellij-plugin-v4#180.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:23 (23 by maintainers)

github_iconTop GitHub Comments

1reaction
marcospassoscommented, Dec 13, 2016

As soon as I get home I’ll provide small grammar that shows up this bug and then we discuss the best way to fix it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

matching an unwanted token in Antlr for error reporting
You can't really have a successful parse without all of the input being recognized and tokenized. (A failure to tokenize it, will result...
Read more >
Mint-made errors - Wikipedia
Mint-made errors are errors during the minting process. Groups of coins with distinctive ... Being unique does not mean that an error is...
Read more >
Troubleshooting Invalid Access Tokens - Twilio Support
The most common error codes for Access Tokens are due to incorrect account data or timestamp issues: Error 20103 Invalid Access Token issuer/subject;...
Read more >
Rule-based matching · spaCy Usage Documentation
Find phrases and tokens, and match entities. ... let you define sequences of tokens to be matched, e.g. one or more punctuation marks,...
Read more >
My cost basis / return / capital gain / market value is incorrect ...
In some cases a transfer is mismatched and needs to be edited manually to ensure that the correct sides of the transaction are...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found