github.com/goplus/gossa@v0.3.25/pkg/go/printer/go114_export.go (about)

     1  // export by github.com/goplus/gossa/cmd/qexp
     2  
     3  //+build go1.14,!go1.15
     4  
     5  package printer
     6  
     7  import (
     8  	q "go/printer"
     9  
    10  	"go/constant"
    11  	"reflect"
    12  
    13  	"github.com/goplus/gossa"
    14  )
    15  
    16  func init() {
    17  	gossa.RegisterPackage(&gossa.Package{
    18  		Name: "printer",
    19  		Path: "go/printer",
    20  		Deps: map[string]string{
    21  			"bytes":          "bytes",
    22  			"fmt":            "fmt",
    23  			"go/ast":         "ast",
    24  			"go/token":       "token",
    25  			"io":             "io",
    26  			"math":           "math",
    27  			"os":             "os",
    28  			"strconv":        "strconv",
    29  			"strings":        "strings",
    30  			"text/tabwriter": "tabwriter",
    31  			"unicode":        "unicode",
    32  			"unicode/utf8":   "utf8",
    33  		},
    34  		Interfaces: map[string]reflect.Type{},
    35  		NamedTypes: map[string]gossa.NamedType{
    36  			"CommentedNode": {reflect.TypeOf((*q.CommentedNode)(nil)).Elem(), "", ""},
    37  			"Config":        {reflect.TypeOf((*q.Config)(nil)).Elem(), "", "Fprint,fprint"},
    38  			"Mode":          {reflect.TypeOf((*q.Mode)(nil)).Elem(), "", ""},
    39  		},
    40  		AliasTypes: map[string]reflect.Type{},
    41  		Vars:       map[string]reflect.Value{},
    42  		Funcs: map[string]reflect.Value{
    43  			"Fprint": reflect.ValueOf(q.Fprint),
    44  		},
    45  		TypedConsts: map[string]gossa.TypedConst{
    46  			"RawFormat": {reflect.TypeOf(q.RawFormat), constant.MakeInt64(int64(q.RawFormat))},
    47  			"SourcePos": {reflect.TypeOf(q.SourcePos), constant.MakeInt64(int64(q.SourcePos))},
    48  			"TabIndent": {reflect.TypeOf(q.TabIndent), constant.MakeInt64(int64(q.TabIndent))},
    49  			"UseSpaces": {reflect.TypeOf(q.UseSpaces), constant.MakeInt64(int64(q.UseSpaces))},
    50  		},
    51  		UntypedConsts: map[string]gossa.UntypedConst{},
    52  	})
    53  }