github.com/goplus/gossa@v0.3.25/pkg/sync/go118_export.go (about)

     1  // export by github.com/goplus/gossa/cmd/qexp
     2  
     3  //go:build go1.18
     4  // +build go1.18
     5  
     6  package sync
     7  
     8  import (
     9  	q "sync"
    10  
    11  	"reflect"
    12  
    13  	"github.com/goplus/gossa"
    14  )
    15  
    16  func init() {
    17  	gossa.RegisterPackage(&gossa.Package{
    18  		Name: "sync",
    19  		Path: "sync",
    20  		Deps: map[string]string{
    21  			"internal/race": "race",
    22  			"runtime":       "runtime",
    23  			"sync/atomic":   "atomic",
    24  			"unsafe":        "unsafe",
    25  		},
    26  		Interfaces: map[string]reflect.Type{
    27  			"Locker": reflect.TypeOf((*q.Locker)(nil)).Elem(),
    28  		},
    29  		NamedTypes: map[string]gossa.NamedType{
    30  			"Cond":      {reflect.TypeOf((*q.Cond)(nil)).Elem(), "", "Broadcast,Signal,Wait"},
    31  			"Map":       {reflect.TypeOf((*q.Map)(nil)).Elem(), "", "Delete,Load,LoadAndDelete,LoadOrStore,Range,Store,dirtyLocked,missLocked"},
    32  			"Mutex":     {reflect.TypeOf((*q.Mutex)(nil)).Elem(), "", "Lock,TryLock,Unlock,lockSlow,unlockSlow"},
    33  			"Once":      {reflect.TypeOf((*q.Once)(nil)).Elem(), "", "Do,doSlow"},
    34  			"Pool":      {reflect.TypeOf((*q.Pool)(nil)).Elem(), "", "Get,Put,getSlow,pin,pinSlow"},
    35  			"RWMutex":   {reflect.TypeOf((*q.RWMutex)(nil)).Elem(), "", "Lock,RLock,RLocker,RUnlock,TryLock,TryRLock,Unlock,rUnlockSlow"},
    36  			"WaitGroup": {reflect.TypeOf((*q.WaitGroup)(nil)).Elem(), "", "Add,Done,Wait,state"},
    37  		},
    38  		AliasTypes: map[string]reflect.Type{},
    39  		Vars:       map[string]reflect.Value{},
    40  		Funcs: map[string]reflect.Value{
    41  			"NewCond": reflect.ValueOf(q.NewCond),
    42  		},
    43  		TypedConsts:   map[string]gossa.TypedConst{},
    44  		UntypedConsts: map[string]gossa.UntypedConst{},
    45  	})
    46  }