Registry / other / antlr4-go-antlr-v4

antlr4-go-antlr-v4

JSON →
library4.13.1gogounverified

Package antlr implements the Go version of the ANTLR 4 runtime for parsing structured text.

go get github.com/antlr4-go/antlr/v4
INSTALL
IMPORT
SIG · ANTLR4-GO-ANTLR-V4
A
antlr4-go-antlr-v4
othergov4.13.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

antlr
github.com/antlr4-go/antlr/v4

Creates an ANTLR input stream and lexer.

package main import ( "fmt" "github.com/antlr4-go/antlr/v4" ) func main() { // Create a lexer from input input := antlr.NewInputStream("hello") lexer := antlr.NewLexer(input, nil) // simplified; actual usage requires generated lexer fmt.Println(lexer) }
Debug
Known issues
gotchaThe ANTLR Go runtime requires generated parser code from the ANTLR tool; it is not a standalone parser.
fix
Use the ANTLR tool to generate parser code from your grammar files.
affects: >=4.13.0
Upgrade
Version history
4.13.1latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
15 hits · last 30 days
node
12
Meta
2
OpenAI (training)
1
Resources
antlr4-go-antlr-v4 — go get antlr4-go-antlr-v4 · libregistry