-
Notifications
You must be signed in to change notification settings - Fork 14
/
go120_export.go
executable file
·59 lines (53 loc) · 2.12 KB
/
go120_export.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
// export by github.com/goplus/igop/cmd/qexp
//go:build go1.20
// +build go1.20
package parser
import (
q "go/parser"
"go/constant"
"reflect"
"github.com/goplus/igop"
)
func init() {
igop.RegisterPackage(&igop.Package{
Name: "parser",
Path: "go/parser",
Deps: map[string]string{
"bytes": "bytes",
"errors": "errors",
"fmt": "fmt",
"go/ast": "ast",
"go/internal/typeparams": "typeparams",
"go/scanner": "scanner",
"go/token": "token",
"io": "io",
"io/fs": "fs",
"os": "os",
"path/filepath": "filepath",
"strings": "strings",
},
Interfaces: map[string]reflect.Type{},
NamedTypes: map[string]reflect.Type{
"Mode": reflect.TypeOf((*q.Mode)(nil)).Elem(),
},
AliasTypes: map[string]reflect.Type{},
Vars: map[string]reflect.Value{},
Funcs: map[string]reflect.Value{
"ParseDir": reflect.ValueOf(q.ParseDir),
"ParseExpr": reflect.ValueOf(q.ParseExpr),
"ParseExprFrom": reflect.ValueOf(q.ParseExprFrom),
"ParseFile": reflect.ValueOf(q.ParseFile),
},
TypedConsts: map[string]igop.TypedConst{
"AllErrors": {reflect.TypeOf(q.AllErrors), constant.MakeInt64(int64(q.AllErrors))},
"DeclarationErrors": {reflect.TypeOf(q.DeclarationErrors), constant.MakeInt64(int64(q.DeclarationErrors))},
"ImportsOnly": {reflect.TypeOf(q.ImportsOnly), constant.MakeInt64(int64(q.ImportsOnly))},
"PackageClauseOnly": {reflect.TypeOf(q.PackageClauseOnly), constant.MakeInt64(int64(q.PackageClauseOnly))},
"ParseComments": {reflect.TypeOf(q.ParseComments), constant.MakeInt64(int64(q.ParseComments))},
"SkipObjectResolution": {reflect.TypeOf(q.SkipObjectResolution), constant.MakeInt64(int64(q.SkipObjectResolution))},
"SpuriousErrors": {reflect.TypeOf(q.SpuriousErrors), constant.MakeInt64(int64(q.SpuriousErrors))},
"Trace": {reflect.TypeOf(q.Trace), constant.MakeInt64(int64(q.Trace))},
},
UntypedConsts: map[string]igop.UntypedConst{},
})
}