Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 29 of 29 for NewPointer (0.18 sec)

  1. src/go/internal/gcimporter/ureader.go

    	case pkgbits.TypeChan:
    		dir := types.ChanDir(r.Len())
    		return types.NewChan(dir, r.typ())
    	case pkgbits.TypeMap:
    		return types.NewMap(r.typ(), r.typ())
    	case pkgbits.TypePointer:
    		return types.NewPointer(r.typ())
    	case pkgbits.TypeSignature:
    		return r.signature(nil, nil, nil)
    	case pkgbits.TypeSlice:
    		return types.NewSlice(r.typ())
    	case pkgbits.TypeStruct:
    		return r.structType()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 16.6K bytes
    - Viewed (0)
  2. src/go/internal/gcimporter/iimport.go

    		return nil
    
    	case definedType:
    		pkg, name := r.qualifiedIdent()
    		r.p.doDecl(pkg, name)
    		return pkg.Scope().Lookup(name).(*types.TypeName).Type()
    	case pointerType:
    		return types.NewPointer(r.typ())
    	case sliceType:
    		return types.NewSlice(r.typ())
    	case arrayType:
    		n := r.uint64()
    		return types.NewArray(r.typ(), int64(n))
    	case chanType:
    		dir := chanDir(int(r.uint64()))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 19.2K bytes
    - Viewed (0)
  3. src/go/internal/gcimporter/gcimporter_test.go

    	_, err := Import(fset, imports, "net/http", ".", nil)
    	if err != nil {
    		t.Fatal(err)
    	}
    
    	mutex := imports["sync"].Scope().Lookup("Mutex").(*types.TypeName).Type()
    	mset := types.NewMethodSet(types.NewPointer(mutex)) // methods of *sync.Mutex
    	sel := mset.Lookup(nil, "Lock")
    	lock := sel.Obj().(*types.Func)
    	if got, want := lock.Pkg().Path(), "sync"; got != want {
    		t.Errorf("got package path %q; want %q", got, want)
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 16:22:59 UTC 2024
    - 21.9K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/types2/api_test.go

    		{Typ[UntypedInt], Typ[Int], true},
    		{NewSlice(Typ[Int]), NewArray(Typ[Int], 10), true},
    		{NewSlice(Typ[Int]), NewArray(Typ[Uint], 10), false},
    		{NewSlice(Typ[Int]), NewPointer(NewArray(Typ[Int], 10)), true},
    		{NewSlice(Typ[Int]), NewPointer(NewArray(Typ[Uint], 10)), false},
    		// Untyped string values are not permitted by the spec, so the behavior below is undefined.
    		{Typ[UntypedString], Typ[String], true},
    	} {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 93.3K bytes
    - Viewed (0)
  5. src/go/types/api_test.go

    		{Typ[UntypedInt], Typ[Int], true},
    		{NewSlice(Typ[Int]), NewArray(Typ[Int], 10), true},
    		{NewSlice(Typ[Int]), NewArray(Typ[Uint], 10), false},
    		{NewSlice(Typ[Int]), NewPointer(NewArray(Typ[Int], 10)), true},
    		{NewSlice(Typ[Int]), NewPointer(NewArray(Typ[Uint], 10)), false},
    		// Untyped string values are not permitted by the spec, so the behavior below is undefined.
    		{Typ[UntypedString], Typ[String], true},
    	} {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 94.2K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/types2/named.go

    		// No substitution occurred, but we still need to create a new signature to
    		// hold the instantiated receiver.
    		copy := *origSig
    		sig = &copy
    	}
    
    	var rtyp Type
    	if origm.hasPtrRecv() {
    		rtyp = NewPointer(t)
    	} else {
    		rtyp = t
    	}
    
    	sig.recv = substVar(origSig.recv, rtyp)
    	return substFunc(origm, sig)
    }
    
    // SetUnderlying sets the underlying type and marks t as complete.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 20:03:31 UTC 2024
    - 23.9K bytes
    - Viewed (0)
  7. src/go/types/named.go

    		// No substitution occurred, but we still need to create a new signature to
    		// hold the instantiated receiver.
    		copy := *origSig
    		sig = &copy
    	}
    
    	var rtyp Type
    	if origm.hasPtrRecv() {
    		rtyp = NewPointer(t)
    	} else {
    		rtyp = t
    	}
    
    	sig.recv = substVar(origSig.recv, rtyp)
    	return substFunc(origm, sig)
    }
    
    // SetUnderlying sets the underlying type and marks t as complete.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 20:03:31 UTC 2024
    - 24K bytes
    - Viewed (0)
  8. api/go1.5.txt

    pkg go/types, func NewPackage(string, string) *Package
    pkg go/types, func NewParam(token.Pos, *Package, string, Type) *Var
    pkg go/types, func NewPkgName(token.Pos, *Package, string, *Package) *PkgName
    pkg go/types, func NewPointer(Type) *Pointer
    pkg go/types, func NewScope(*Scope, token.Pos, token.Pos, string) *Scope
    pkg go/types, func NewSignature(*Var, *Tuple, *Tuple, bool) *Signature
    pkg go/types, func NewSlice(Type) *Slice
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jul 30 21:14:09 UTC 2015
    - 46.6K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go

    		{"NewLabel", Func, 5},
    		{"NewMap", Func, 5},
    		{"NewMethodSet", Func, 5},
    		{"NewNamed", Func, 5},
    		{"NewPackage", Func, 5},
    		{"NewParam", Func, 5},
    		{"NewPkgName", Func, 5},
    		{"NewPointer", Func, 5},
    		{"NewScope", Func, 5},
    		{"NewSignature", Func, 5},
    		{"NewSignatureType", Func, 18},
    		{"NewSlice", Func, 5},
    		{"NewStruct", Func, 5},
    		{"NewTerm", Func, 18},
    		{"NewTuple", Func, 5},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 534.2K bytes
    - Viewed (0)
Back to top