Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Printer ¶
type Printer struct {
// contains filtered or unexported fields
}
Printer prints AST nodes
func New ¶
New returns Printer If srcPackageName is not empty Printer assumes that printed node goes to the package different from the srcPackageName and all references to the types listed in typeSpecs should be prepended with the source package name selector
func (*Printer) PrintType ¶
PrintType prints node that represents a type, i.e. type of a function argument or a or struct field If node references one of the types listed in p.types and srcPackageName is not empty it adds source package selector to the type identifier PrintType returns error if the srcPackageName is not empty and the printed type is unexported.
Click to show internal directories.
Click to hide internal directories.