Documentation ¶
Index ¶
- type Argument
- type CHeaderFileAST
- func (a CHeaderFileAST) CollectAliases() []TypedefAlias
- func (a CHeaderFileAST) CollectEnums() []TypedefEnum
- func (a CHeaderFileAST) CollectFunctions() []TypedefFunction
- func (a CHeaderFileAST) CollectGDExtensionInterfaceFunctions() []TypedefFunction
- func (a CHeaderFileAST) CollectNonGDExtensionInterfaceFunctions() []TypedefFunction
- func (a CHeaderFileAST) CollectStructs() []TypedefStruct
- func (a CHeaderFileAST) FindVariantEnumType() *TypedefEnum
- type EnumValue
- type Expr
- type FunctionType
- type PrimativeType
- type StructField
- type StructFunction
- type StructVariable
- type Type
- type TypedefAlias
- type TypedefEnum
- type TypedefFunction
- type TypedefStruct
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Argument ¶
type Argument struct { Type Type `parser:" @@ " json:",omitempty"` Name string `parser:" ( @Ident | '(' '*' @Ident ')' )? " json:",omitempty"` }
void (*p_func)(void *, uint32_t)
func (Argument) CStyleString ¶
func (Argument) IsPinnable ¶
func (Argument) ResolvedName ¶
type CHeaderFileAST ¶
type CHeaderFileAST struct {
Expr []Expr `parser:" @@* " json:",omitempty"`
}
func ParseCString ¶
func ParseCString(s string) (CHeaderFileAST, error)
func (CHeaderFileAST) CollectAliases ¶
func (a CHeaderFileAST) CollectAliases() []TypedefAlias
func (CHeaderFileAST) CollectEnums ¶
func (a CHeaderFileAST) CollectEnums() []TypedefEnum
func (CHeaderFileAST) CollectFunctions ¶
func (a CHeaderFileAST) CollectFunctions() []TypedefFunction
func (CHeaderFileAST) CollectGDExtensionInterfaceFunctions ¶
func (a CHeaderFileAST) CollectGDExtensionInterfaceFunctions() []TypedefFunction
func (CHeaderFileAST) CollectNonGDExtensionInterfaceFunctions ¶
func (a CHeaderFileAST) CollectNonGDExtensionInterfaceFunctions() []TypedefFunction
func (CHeaderFileAST) CollectStructs ¶
func (a CHeaderFileAST) CollectStructs() []TypedefStruct
func (CHeaderFileAST) FindVariantEnumType ¶ added in v0.3.13
func (a CHeaderFileAST) FindVariantEnumType() *TypedefEnum
type Expr ¶
type Expr struct { Comment string `parser:" @Comment " json:",omitempty"` Enum *TypedefEnum `parser:" | @@ ';' " json:",omitempty"` Alias *TypedefAlias `parser:" | @@ ';' " json:",omitempty"` Function *TypedefFunction `parser:" | @@ ';' " json:",omitempty"` Struct *TypedefStruct `parser:" | @@ ';' " json:",omitempty"` }
type FunctionType ¶
type FunctionType struct { ReturnType PrimativeType `parser:" @@ " json:",omitempty"` Name string `parser:" '(' '*' @Ident ')' " json:",omitempty"` Arguments []Argument `parser:" '(' ( @@ ( ',' @@ )* )? ')' " json:",omitempty"` }
func (FunctionType) CStyleString ¶
func (t FunctionType) CStyleString() string
type PrimativeType ¶
type PrimativeType struct { IsConst bool `parser:" @'const'? " json:",omitempty"` Name string `parser:" @Ident " json:",omitempty"` IsPointer bool `parser:" @'*'? " json:",omitempty"` }
func (PrimativeType) CStyleString ¶
func (t PrimativeType) CStyleString() string
type StructField ¶
type StructField struct { Variable *StructVariable `parser:" ( @@ " json:",omitempty"` Function *StructFunction `parser:" | @@ ) ';' " json:",omitempty"` }
type StructFunction ¶
type StructFunction struct { ReturnType PrimativeType `parser:" @@ " json:",omitempty"` Name string `parser:" '(' '*' @Ident ')' " json:",omitempty"` Arguments []Argument `parser:" '(' @@ ( ',' @@ )* ')' " json:",omitempty"` Comment string `parser:" @Comment? " json:",omitempty"` }
type StructVariable ¶
type StructVariable struct { Type PrimativeType `parser:" @@ " json:",omitempty"` Name string `parser:" @Ident " json:",omitempty"` }
type Type ¶
type Type struct { Function *FunctionType `parser:" ( @@ " json:",omitempty"` Primative *PrimativeType `parser:" | @@ ) " json:",omitempty"` }
func (Type) CStyleString ¶
type TypedefAlias ¶
type TypedefAlias struct { Type PrimativeType `parser:" 'typedef' @@ " json:",omitempty"` Name string `parser:" @Ident " json:",omitempty"` }
type TypedefEnum ¶
type TypedefFunction ¶
type TypedefFunction struct { ReturnType PrimativeType `parser:" 'typedef' @@ " json:",omitempty"` Name string `parser:" '(' '*' @Ident ')' " json:",omitempty"` Arguments []Argument `parser:" '(' ( @@ ( ',' @@ )* )? ')' " json:",omitempty"` }
type TypedefStruct ¶
type TypedefStruct struct { Fields []StructField `parser:" 'typedef' 'struct' '{' @@* '}' " json:",omitempty"` Name string `parser:" @Ident " json:",omitempty"` }
func (TypedefStruct) CollectFunctions ¶
func (t TypedefStruct) CollectFunctions() []StructFunction
Click to show internal directories.
Click to hide internal directories.