package
Version:
v0.13.6
Opens a new window with list of versions in this module.
Published: Dec 13, 2023
License: MIT
Opens a new window with license information.
Imports: 3
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
type File struct {
Statements []*Statement `(@@ | ANY | ALL | String | Punct | PathSep | Ident)*`
Path string
}
type Mod struct {
Pub bool `@"pub"? ("(" (Ident | PathSep)* ")")? "mod"`
Name string `@Ident`
Local bool `@"{"?`
}
type Name struct {
Original string `@Ident`
Alias string `("as" @Ident)?`
}
type Pub struct {
Name string ``
}
type Statement struct {
Mod *Mod `@@`
Use *Use `| @@`
Pub *Pub `| @@`
}
type Use struct {
Pub bool `@"pub"? ("(" (Ident | PathSep)* ")")?`
UsePath *UsePath `"use" @@ ";"`
}
type UsePath struct {
PathSlices []string `(@Ident PathSep)*`
All bool `(@ALL |`
Name *Name ` @@ |`
UsePaths []*UsePath ` "{" @@ ("," @@)* "}" )`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.