Comments (1)
If you pass the outer context into predTransition
, it solves the problem of tracking the correct context for full-context prediction, but doesn't help local-context prediction. In the local-context case, the outer context never appears in the ATNConfig
to use as a comparison basis. The depth tracking here is inexpensive and a single solution to both the full-context and local-context problems.
The unit test testJavaExpressions
already tests this issue, strangely enough by passing when it should be failing. With the current implementation of LR rules and the current rules for prioritizing predicated alts over unpredicated alts, the following expression cannot be parsed correctly. With the issue corrected, the testJavaExpressions
test will fail, highlighting the underlying issue with predicate precedence.
new T[((n-1) * x) + 1]
from antlr4.
Related Issues (20)
- How to get parent of the node using antlr4 typescript HOT 5
- Usage of `\p{Alpha}` does not work as expected on earlier versions of JDK 17
- ATN.NextToken(state) should be memoized HOT 3
- PL/SQL grammar cannot recognise identifiers that start with keywords HOT 2
- Migration bug in golang runtime HOT 5
- Could not deserialize ATN with version 3 (expected 4) with Hibernate 6 HOT 3
- Tool does not generate any constants for channels for the TypeScript target HOT 5
- Generate an abstract class/interface for rule containing only other parser rules as unnamed subrules
- [Swift] Add privacy manifest HOT 2
- [Go] Type signature error
- How can we write multiple parsers to use the same lexer? HOT 1
- [CSharp] Member GetMaxTokenType missing in IVocabulary
- Missing TypeScript methods
- [TorqueScript: C++]Old scripting language conversion HOT 2
- Inquiry Regarding Runtime Performance of ANTLR4 in Rust
- Left recursive rules that do not conform to a pattern ANTLR can handle HOT 1
- Android Tool run
- Separated package/artifactId when the minor version is upgraded for compatibility issues
- [Go] Can not use BailErrorStrategy since ParseCancellationException is not implement HOT 1
- Issue with using ANTLR4 from Julia via PyCall
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from antlr4.