Registry / utility / alecthomas-participle-v2

alecthomas-participle-v2

JSON →
library2.1.4gogounverified

Package participle constructs parsers from definitions in struct tags and parses directly into those structs.

go get github.com/alecthomas/participle/v2
INSTALL
IMPORT
SIG · ALECTHOMAS-PARTICI
A
alecthomas-participle-v2
utilitygov2.1.4
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.

participle
github.com/alecthomas/participle/v2

Define a simple grammar and parse input

package main import ( "fmt" "github.com/alecthomas/participle/v2" ) type Grammar struct { Name string `@Ident` } func main() { parser := participle.MustBuild[Grammar]() result, _ := parser.ParseString("", "hello") fmt.Println(result.Name) }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
2.1.4latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
40 hits · last 30 days
node
36
Meta
1
OpenAI (training)
1
Resources
alecthomas-participle-v2 — go get alecthomas-participle-v2 · libregistry