
The highest tagged major version is
v2.
Documentation
¶
type Args struct {
Arguments []Argument `(@@|`
}
Args is both used as the grammar and the tree representation of the abstract
syntactic structure of the command-line arguments.
Parse returns the AST of the command-line arguments.
func (a *Args) Bind(i interface{})
Bind binds the fields of the given struct with matching argument values.
type Argument struct {
Identifier string `@('-'|Let|Num)+`
Value Value `@@?`
}
type Value struct {
Assignment string `@'='`
String string `@(Let|Num|Pun|Sym|Sep)+`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.