-
Notifications
You must be signed in to change notification settings - Fork 14
/
go118_export.go
executable file
·111 lines (105 loc) · 5.61 KB
/
go118_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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
// export by github.com/goplus/igop/cmd/qexp
//go:build go1.18
// +build go1.18
package time
import (
q "time"
"go/constant"
"reflect"
"github.com/goplus/igop"
)
func init() {
igop.RegisterPackage(&igop.Package{
Name: "time",
Path: "time",
Deps: map[string]string{
"errors": "errors",
"runtime": "runtime",
"sync": "sync",
"syscall": "syscall",
"unsafe": "unsafe",
},
Interfaces: map[string]reflect.Type{},
NamedTypes: map[string]reflect.Type{
"Duration": reflect.TypeOf((*q.Duration)(nil)).Elem(),
"Location": reflect.TypeOf((*q.Location)(nil)).Elem(),
"Month": reflect.TypeOf((*q.Month)(nil)).Elem(),
"ParseError": reflect.TypeOf((*q.ParseError)(nil)).Elem(),
"Ticker": reflect.TypeOf((*q.Ticker)(nil)).Elem(),
"Time": reflect.TypeOf((*q.Time)(nil)).Elem(),
"Timer": reflect.TypeOf((*q.Timer)(nil)).Elem(),
"Weekday": reflect.TypeOf((*q.Weekday)(nil)).Elem(),
},
AliasTypes: map[string]reflect.Type{},
Vars: map[string]reflect.Value{
"Local": reflect.ValueOf(&q.Local),
"UTC": reflect.ValueOf(&q.UTC),
},
Funcs: map[string]reflect.Value{
"After": reflect.ValueOf(q.After),
"AfterFunc": reflect.ValueOf(q.AfterFunc),
"Date": reflect.ValueOf(q.Date),
"FixedZone": reflect.ValueOf(q.FixedZone),
"LoadLocation": reflect.ValueOf(q.LoadLocation),
"LoadLocationFromTZData": reflect.ValueOf(q.LoadLocationFromTZData),
"NewTicker": reflect.ValueOf(q.NewTicker),
"NewTimer": reflect.ValueOf(q.NewTimer),
"Now": reflect.ValueOf(q.Now),
"Parse": reflect.ValueOf(q.Parse),
"ParseDuration": reflect.ValueOf(q.ParseDuration),
"ParseInLocation": reflect.ValueOf(q.ParseInLocation),
"Since": reflect.ValueOf(q.Since),
"Sleep": reflect.ValueOf(q.Sleep),
"Tick": reflect.ValueOf(q.Tick),
"Unix": reflect.ValueOf(q.Unix),
"UnixMicro": reflect.ValueOf(q.UnixMicro),
"UnixMilli": reflect.ValueOf(q.UnixMilli),
"Until": reflect.ValueOf(q.Until),
},
TypedConsts: map[string]igop.TypedConst{
"April": {reflect.TypeOf(q.April), constant.MakeInt64(int64(q.April))},
"August": {reflect.TypeOf(q.August), constant.MakeInt64(int64(q.August))},
"December": {reflect.TypeOf(q.December), constant.MakeInt64(int64(q.December))},
"February": {reflect.TypeOf(q.February), constant.MakeInt64(int64(q.February))},
"Friday": {reflect.TypeOf(q.Friday), constant.MakeInt64(int64(q.Friday))},
"Hour": {reflect.TypeOf(q.Hour), constant.MakeInt64(int64(q.Hour))},
"January": {reflect.TypeOf(q.January), constant.MakeInt64(int64(q.January))},
"July": {reflect.TypeOf(q.July), constant.MakeInt64(int64(q.July))},
"June": {reflect.TypeOf(q.June), constant.MakeInt64(int64(q.June))},
"March": {reflect.TypeOf(q.March), constant.MakeInt64(int64(q.March))},
"May": {reflect.TypeOf(q.May), constant.MakeInt64(int64(q.May))},
"Microsecond": {reflect.TypeOf(q.Microsecond), constant.MakeInt64(int64(q.Microsecond))},
"Millisecond": {reflect.TypeOf(q.Millisecond), constant.MakeInt64(int64(q.Millisecond))},
"Minute": {reflect.TypeOf(q.Minute), constant.MakeInt64(int64(q.Minute))},
"Monday": {reflect.TypeOf(q.Monday), constant.MakeInt64(int64(q.Monday))},
"Nanosecond": {reflect.TypeOf(q.Nanosecond), constant.MakeInt64(int64(q.Nanosecond))},
"November": {reflect.TypeOf(q.November), constant.MakeInt64(int64(q.November))},
"October": {reflect.TypeOf(q.October), constant.MakeInt64(int64(q.October))},
"Saturday": {reflect.TypeOf(q.Saturday), constant.MakeInt64(int64(q.Saturday))},
"Second": {reflect.TypeOf(q.Second), constant.MakeInt64(int64(q.Second))},
"September": {reflect.TypeOf(q.September), constant.MakeInt64(int64(q.September))},
"Sunday": {reflect.TypeOf(q.Sunday), constant.MakeInt64(int64(q.Sunday))},
"Thursday": {reflect.TypeOf(q.Thursday), constant.MakeInt64(int64(q.Thursday))},
"Tuesday": {reflect.TypeOf(q.Tuesday), constant.MakeInt64(int64(q.Tuesday))},
"Wednesday": {reflect.TypeOf(q.Wednesday), constant.MakeInt64(int64(q.Wednesday))},
},
UntypedConsts: map[string]igop.UntypedConst{
"ANSIC": {"untyped string", constant.MakeString(string(q.ANSIC))},
"Kitchen": {"untyped string", constant.MakeString(string(q.Kitchen))},
"Layout": {"untyped string", constant.MakeString(string(q.Layout))},
"RFC1123": {"untyped string", constant.MakeString(string(q.RFC1123))},
"RFC1123Z": {"untyped string", constant.MakeString(string(q.RFC1123Z))},
"RFC3339": {"untyped string", constant.MakeString(string(q.RFC3339))},
"RFC3339Nano": {"untyped string", constant.MakeString(string(q.RFC3339Nano))},
"RFC822": {"untyped string", constant.MakeString(string(q.RFC822))},
"RFC822Z": {"untyped string", constant.MakeString(string(q.RFC822Z))},
"RFC850": {"untyped string", constant.MakeString(string(q.RFC850))},
"RubyDate": {"untyped string", constant.MakeString(string(q.RubyDate))},
"Stamp": {"untyped string", constant.MakeString(string(q.Stamp))},
"StampMicro": {"untyped string", constant.MakeString(string(q.StampMicro))},
"StampMilli": {"untyped string", constant.MakeString(string(q.StampMilli))},
"StampNano": {"untyped string", constant.MakeString(string(q.StampNano))},
"UnixDate": {"untyped string", constant.MakeString(string(q.UnixDate))},
},
})
}