astparsing

package
v2.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 28, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadPackagesRecursive

func LoadPackagesRecursive(path string) ([]*packages.Package, error)

Types

type CommandBuilderFunc

type CommandBuilderFunc struct {
	// contains filtered or unexported fields
}

type CommandBuilderInfo

type CommandBuilderInfo struct {
	Pkg               *packages.Package
	CommandOptsStruct *ast.TypeSpec
	TemplateIdent     *ast.Ident
	TemplateType      *NamedStructInfo
	TemplateValue     string
}

func LoadCommandBuilderInfos

func LoadCommandBuilderInfos(packages []*packages.Package) []*CommandBuilderInfo

type NamedStructInfo

type NamedStructInfo struct {
	NamedStruct *types.Named
	StructInfo  *types.Struct
}

func GetUnderlyingStruct

func GetUnderlyingStruct(v types.Type) (*NamedStructInfo, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL