NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
NuGet
NuGet, #1065 most downloaded on NuGet
The .NET Core C# ANTLR 4 runtime from the ANTLR Organization
Latest stable
4.13.1
Last release 3 years ago
no release in 18 months
Ships fairly regularly
a new release about every 5 months
Nearly every release is documented
notes for 15 of 16 stable releases
Nothing withdrawn
no release was ever pulled
10 years old
16 releases · first in 2016
Drag across the ruler to compare, or tap a release to open it.
[[CSharp] Fix for #4386 -- change signatures for ReportAttemptingFullContext() and ReportContextSensitivity() to be identical to all other targets](ht
this-escape warning introduced in JDK 21. (actions, target:java)Your coding agent can read these notes before it upgrades. Set up the MCP server →
This is primarily change to the Go target itself and its release location, which has moved to https://github.com/antlr4-go/antlr. The code still lives
This is primarily change to the Go target itself and its release location, which has moved to https://github.com/antlr4-go/antlr. The code still lives and this repository, but for release purposes we've created a new organization and repository so that Go users can pull versions down according to the repository and label rules
PEP 621-compliant pyproject.toml. (comp:build, target:python3)The 4.12.0 release is primarily about the new TypeScript target created by @ericvergnaud. There are also a number of fixes to the various targets, as
The 4.12.0 release is primarily about the new TypeScript target created by @ericvergnaud. There are also a number of fixes to the various targets, as you can see from the descriptions below.
Just fixes 4.11.0 release issue. I forgot to change runtime tool version so it didn't say SNAPSHOT.
Just fixes 4.11.0 release issue. I forgot to change runtime tool version so it didn't say SNAPSHOT.
4.11.1 (just fixes 4.11.0 release issue)
Compare
Tiny update to fix build issue where java requirement for runtime was 11 not 1.8.
Tiny update to fix build issue where java requirement for runtime was 11 not 1.8.
Full Changelog: https://github.com/antlr/antlr4/compare/v4.10.0...4.10.1
[[C++] Cleanup ATNDeserializer and remove related deprecated methods from ATNSimulator](https://github.com/antlr/antlr4/pull/3545) (target:cpp, type:c…
This is a very major release with a number of important changes. There have been many valuable contributions, but I welcome @KvanTTT and @jcking as recent "official" major ANTLR contributors. :)
WARNING: Generated 4.10 lexers and parsers are incompatible with code generated by previous versions of ANTLR. You must regenerate all of your code from grammars to use the new runtime. This is true of all targets (except probably javascript).
We have changed the branching structure of the repository. The default branch for this repo remains master and it is the latest stable release with tags for the various releases; e.g., see release tag 4.9.3. We now do development work in branch dev between releases and all pull requests should be derived from that branch. The dev branch is merged back into master to cut a release and the release state is tagged (e.g., with 4.10-rc.1 or 4.10.) Visually our process looks roughly like this:
<img src="https://github.com/antlr/antlr4/raw/master/doc/images/new-antlr-branches.png" width="500">
Targets such as Go that pull directly from the repository can use the default master branch but can also pull from the active dev branch:
$ go get github.com/antlr/antlr4/runtime/Go/antlr@dev
In order to bring ANTLR more in line with current standard standards for contribution processes, as of 4.10, ANTLR uses the Linux Foundation's Developer Certificate of Origin, DCO, version 1.1. See file https://github.com/antlr/antlr4/raw/master/developer-cert-of-origin.txt . It is simpler than the original contributors license agreement, which required programmers to sign the contributors.txt file, which has now moved to file historical-contributors-agreement.txt .
Each commit in pull requests must have a "signature", which is simple as using -s (not -S) on the git commit command:
$ git commit -s -m 'This is my commit message'
Github's pull request process enforces the sig and gives instructions on how to fix any commits that lack the sig. See https://github.com/apps/dco for more info.
ANTLR not only generates recursive-descent parsers; it generates a state machine called an augmented transition network (ATN) in serialized form as a bunch of integers stored in the generated parser and lexer files. This serialization format was changed for 4.10 to remove a size limit on the supported ATNs. See https://github.com/antlr/antlr4/pull/3591.
The key point here is that we changed the version number stored inside the serialization format and so, in order to use this new version of ANTLR, you must regenerate all of your lexers and parsers using the 4.10 tool and then use the new runtime. Parsers generated with 4.10 or not compatible with previous versions of the runtime.
Going forward, we are using Java 11 for the source code and the compiled .class files for the ANTLR tool. The Java runtime target, however, and the associated runtime tests use Java 8 (bumping up from Java 7).
The JS target has been substantially reworked.
caseInsensitive option now.The following report is generated by scripts/github_release_notes.py.
AnyObject instead of class. (target:swift)late modifier for Dart generated context classes (target:dart)Full Changelog: https://github.com/antlr/antlr4/compare/4.9.3...4.10
4.10 Major feature, code clean up, and bug fix release
Compare
Upgrade com.ibm.icu:icu4j to latest (69.1) to avoid potential vulnerabilities it brings (target:java, unicode)
go.mod to go runtime module (comp:build, target:go)CSharp and Java produce different results for identical input, identical tokens (target:csharp, type:bug)
Moved away from travis-ci.com.
Invalid C# code being generated (code-gen)
[[C++ runtime] Remove codecvt header (deprecated in C++17) in cpp runtime.](https://github.com/antlr/antlr4/pull/2892) (target:cpp)
Thanks to @lingyv-li, we have a DART target!
Thanks to @marcospassos, ANTLR 4.8 introduces a PHP target! See PHP PRs
Thanks to @marcospassos, ANTLR 4.8 introduces a PHP target! See PHP PRs
Antlrv4 failed installation (actions)
contextSuperClass='antlr4::RuleContextWithAltNum' doesn't work (target:cpp)_loadString parameter (target:javascript)Remove use of deprecated String functions (target:swift)
ANTLR version 4.7.1 is a minor release but with lots of little improvements and bug fixes. You can find the pull requests grouped by target language below. Also, please find below the contributor list (auto-generated from the issues and pull request).
modes into other lexer grammars [...]-o and -lib commandline options didn't always do the obvious thing and in fact presented some problems. With clean that up but requires a new -Xexact-output-dir command line option to enable it to avoid breaking tools built on previous versions of ANTLR [...]new keyword to return proper InputStreams (target:javascript, type:bug)Rather than gutting and changing the interface of the previous ANTLRFileStream etc..., I have deprecated those and introduced a CharStreams.fromXXX fa…
ANTLR version 4.7 is a major release with many improvements and bug fixes.
The primary improvement is that ANTLR and all code generation targets can now handle full 21-bit unicode thanks to the superhuman effort of Ben Hamilton, @bhamiltoncx. After much thought concerning the "create stream" interface, I have decided on the following end result: C++, Python, Go, and Swift APIs didn't need any changes to support full Unicode code points, so I decided to leave those alone. Java, C#, and JavaScript runtimes required changes. Rather than gutting and changing the interface of the previous ANTLRFileStream etc..., I have deprecated those and introduced a CharStreams.fromXXX factory style interface for creating streams. For example, CharStreams.fromFileName("foo.txt")). See the new unicode documentation and a complete list of all pull requests related to Unicode.
UnbufferedCharStream for Java and C# targets was upgraded to use UTF-8 rather than the locale default encoding; they further support U+10FFFF Unicode code points. C++ is the only other target with the unbuffered stream and it worked as-is.
In addition to creating CharStreams capable of supporting 21-bit Unicode, we added notation for Unicode code points beyond 16 bits (4 hexadecimal digits). The usual notation \uABCD still works for the basic code points but you can now use \u{1FFFF}..\u{10FFFF} to access the full range:
You can also include all characters matching Unicode properties such as [\p{Emoji}]:
The C# target now supports .NET Core Support, thanks to David Neumann @lecode-official and Dong Xie @xied75!
We did quite a bit of cleaning up in the lexer escape char and char set areas (big thanks to Ivan Kochurkin @KvanTTT):
The Go runtime was significantly speeded up.
The XPath tree matching library used an ANTLR grammar itself, which caused a cyclic dependency in the build whereby ANTLR version v was required to build version v. I implemented a handbuilt lexer to get rid of this dependency on a grammar: XPathLexer not updated in release process, Fixes #1620. Make handbuilt lexer to avoid cyclic dependence of tool and plugin.
The Java, Swift, and C++ targets have added a hook to the construction of parse tree leaf nodes: factor out the creation of error nodes and terminal nodes in the parser. Code new TerminalNodeImpl(..) and new ErrorNodeImpl(...) instead now calls a few factory methods in the Parser that you can override in your application.
C++ target:
JavaScript target:
Python2/3:
C#:
Go:
Java:
Swift:
Tool or all-target-runtime related:
ANTLR version 4.6 is a major release with many features and bug fixes.
ANTLR version 4.6 is a major release with many features and bug fixes.
e : e '*' e | INT ;). Sam noticed that the parsing engine detected an ambiguity between two choices and resolved it properly but that both would lead to a valid parse. It turns out that the first choice is what led to really slow parsing but the second choice is much faster and still yields a valid parse. Most targets have added that improvement. Here is the discussion of the issue and solution and the primary patch for java.sync() calls back in for LL(1) decisions. (code-gen, error-handling)sync() calls back in for LL(1) decisions. (code-gen, error-handling)Nothing published for this version
One column per quarter.