antlr / antlr4

ANTLR (ANother Tool for Language Recognition) is a powerful parser generator for reading, processing, executing, or translating structured text or binary files.
http://antlr.org
BSD 3-Clause "New" or "Revised" License
17.03k stars 3.27k forks source link

[Java] antlr-runtime is a dependency of antlr4 #4337

Open kortemik opened 1 year ago

kortemik commented 1 year ago

while i was tracing antlr4 versions in our project i noticed that antlr-runtime version 3.5.3 is being included.

previous discussion about the topic #858

https://mvnrepository.com/artifact/org.antlr/antlr4/4.13.0 states as dependencies:

com.ibm.icu » icu4j | 72.1 
org.abego.treelayout » org.abego.treelayout.core | 1.0.3 
org.antlr » antlr4-runtime | 4.13.0 
org.antlr » antlr-runtime | 3.5.3 
org.antlr » ST4 | 4.3.4 

Note: This artifact was moved to:

org.antlr » antlr4-runtime

mvnrepository.com states about antlr-runtime that:

Note: This artifact was moved to:

[org.antlr](https://mvnrepository.com/artifact/org.antlr) » [antlr4-runtime](https://mvnrepository.com/artifact/org.antlr/antlr4-runtime)

If this is still true what is mentioned in #858 would it be possible to use the antlr-runtime in such a manner that it will not be included in the dependencies. examples of this kind of exclusion are included in: https://stackoverflow.com/questions/30113645/how-to-use-maven-to-generate-code-and-package-it-without-dependencies

ericvergnaud commented 1 year ago

Hi, what problem would that solve ?

kortemik commented 1 year ago

Hi, it would trim down the size of dependencies and I think that shipping dependencies that are not part of the end runtime requirements is suboptimal.

ericvergnaud commented 1 year ago

They are part of the tool requirement.If you just need the runtime you should use antlr4-runtime, not antlr4-complete