NewVariable creates a new variable declaration.
(name string, t *types.Type)
| 1031 | |
| 1032 | // NewVariable creates a new variable declaration. |
| 1033 | func NewVariable(name string, t *types.Type) *VariableDecl { |
| 1034 | return &VariableDecl{name: name, varType: t} |
| 1035 | } |
| 1036 | |
| 1037 | // NewVariableWithDoc creates a new variable declaration with usage documentation. |
| 1038 | func NewVariableWithDoc(name string, t *types.Type, doc string) *VariableDecl { |
no outgoing calls