Top "Antlr" questions

ANTLR, ANother Tool for Language Recognition, is a language tool that provides a framework for constructing recognizers, interpreters, compilers, and translators from grammatical descriptions containing actions in a variety of target languages.

Removing Left Recursion in ANTLR

As is explained in Removing left recursion , there are two ways to remove the left recursion. Modify the original grammar …

antlr compiler-theory
Can Xtext be used for parsing general purpose programming languages?

I'm currently developing a general-purpose agent-based programming language (its syntaxt will be somewhat inspired by Java, and we are also …

parsing antlr antlr3 xtext
ANTLR What is simpliest way to realize python like indent-depending grammar?

I am trying realize python like indent-depending grammar. Source example: ABC QWE CDE EFG EFG CDE ABC QWE ZXC As …

antlr lexer indentation
ANTLR 4 tree inject/rewrite operator

In ANTLR 3 you could just do the following: andExpression : (andnotExpression -> andnotExpression) (AND? a=andnotExpression -> ^(AndNode $andExpression $…

antlr antlr3 antlr4
Semantic predicates in ANTLR4?

How would you translate this portion of code written in ANTLR 3 into ANTLR 4? expr: (Identifier '.')=> (refIdentifier) | (Identifier …

antlr antlr4
Does logical AND and NOT exists in ANTLR?

Is there NOT logic in ANTLR? Im basically trying to negate a rule that i have and was wondering if …

antlr grammar antlr3 formal-languages
antlr3 - Generating a Parse Tree

I'm having trouble figuring out the antlr3 API so I can generate and use a parse tree in some javascript …

antlr antlr3 antlrworks parse-tree
Parsing Newlines, EOF as End-of-Statement Marker with ANTLR3

My question is in regards to running the following grammar in ANTLRWorks: INT :('0'..'9')+; SEMICOLON: ';'; …

antlr antlr3 antlrworks
Is there a working C++ grammar file for ANTLR?

Are there any existing C++ grammar files for ANTLR? I'm looking to lex, not parse some C++ source code files. …

c++ antlr lexer
How can I modify the text of tokens in a CommonTokenStream with ANTLR?

I'm trying to learn ANTLR and at the same time use it for a current project. I've gotten to the …

compiler-construction antlr antlr3 lexical-analysis