decl

package
v0.0.0-...-c695042 Latest Latest
Warning

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

Go to latest
Published: May 12, 2022 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Array

func Array(name string, t ast.Expr, exprs []ast.Expr) *ast.GenDecl

Array generates an array declaration.

func Channel

func Channel(c cspinfo.Channel) *ast.CompositeLit

Channel generates a Channel struct declaration

func ChannelArray

func ChannelArray(name string, arr []cspinfo.Channel) *ast.GenDecl

ChannelArray generates an Channel strut array declaration

func Decl

func Decl(tok token.Token, name string, expr ast.Expr) *ast.GenDecl

Decl generates a type value declaration.

func Func

func Func(name string, params *ast.FieldList, results *ast.FieldList) *ast.FuncDecl

Func generates a function declaration.

func Function

func Function(name string, params []*ast.Field, results []*ast.Field, body []ast.Stmt) *ast.FuncDecl

Function generates a function definition.

func Goroutine

func Goroutine(g *cspinfo.Goroutine) *ast.CompositeLit

Goroutine generates a Goroutine struct declaration

func GoroutineArray

func GoroutineArray(name string, arr []*cspinfo.Goroutine) *ast.GenDecl

GoroutineArray generates an Goroutine struct array declaration

func Int

func Int(tok token.Token, name string, value int) *ast.GenDecl

Int generates an integer declaration.

func IntArray

func IntArray(name string, arr []int) *ast.GenDecl

IntArray generates an integer array declaration.

func SimpleArrayType

func SimpleArrayType(arrayType string) ast.Expr

SimpleArrayType generates an array type.

func StringArray

func StringArray(name string, arr []string) *ast.GenDecl

StringArray generates a string array declaration.

func Type

func Type(name *ast.Ident, typeExpr ast.Expr) *ast.GenDecl

Type generates a type alias declaration.

Types

This section is empty.

Jump to

Keyboard shortcuts

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