- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 27 for TypeArgs (0.74 sec)
-
doc/next/6-stdlib/99-minor/go/types/67143.md
The methods [Alias.Origin], [Alias.SetTypeParams], [Alias.TypeParams],
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 15 21:32:30 UTC 2024 - 150 bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/internal/typeparams/common.go
if !Vnamed || !Tnamed { return types.AssignableTo(V, T) } vtparams := VN.TypeParams() ttparams := TN.TypeParams() if vtparams.Len() == 0 || vtparams.Len() != ttparams.Len() || VN.TypeArgs().Len() != 0 || TN.TypeArgs().Len() != 0 { return types.AssignableTo(V, T) } // V and T have the same (non-zero) number of type params. Instantiate both // with the type parameters of V. This must always succeed for V, and will
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 02:38:00 UTC 2024 - 4.3K bytes - Viewed (0) -
src/cmd/compile/internal/types2/subst.go
// TODO(gri) do we need this for Alias types? if t.TypeArgs().Len() != n { return Typ[Invalid] // error reported elsewhere } // already instantiated // For each (existing) type argument determine if it needs // to be substituted; i.e., if it is or contains a type parameter // that has a type argument for it. targs, updated := subst.typeList(t.TypeArgs().list()) if updated {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:04:07 UTC 2024 - 11K bytes - Viewed (0) -
src/go/types/subst.go
// TODO(gri) do we need this for Alias types? if t.TypeArgs().Len() != n { return Typ[Invalid] // error reported elsewhere } // already instantiated // For each (existing) type argument determine if it needs // to be substituted; i.e., if it is or contains a type parameter // that has a type argument for it. targs, updated := subst.typeList(t.TypeArgs().list()) if updated {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:04:07 UTC 2024 - 11.1K bytes - Viewed (0) -
src/cmd/compile/internal/types2/alias.go
func (a *Alias) SetTypeParams(tparams []*TypeParam) { assert(a.targs == nil) a.tparams = bindTParams(tparams) } // TypeArgs returns the type arguments used to instantiate the Alias type. // If a is not an instance of a generic alias, the result is nil. func (a *Alias) TypeArgs() *TypeList { return a.targs } // Rhs returns the type R on the right-hand side of an alias // declaration "type A = R", which may be another alias.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:01:18 UTC 2024 - 5K bytes - Viewed (0) -
src/go/types/alias.go
func (a *Alias) SetTypeParams(tparams []*TypeParam) { assert(a.targs == nil) a.tparams = bindTParams(tparams) } // TypeArgs returns the type arguments used to instantiate the Alias type. // If a is not an instance of a generic alias, the result is nil. func (a *Alias) TypeArgs() *TypeList { return a.targs } // Rhs returns the type R on the right-hand side of an alias // declaration "type A = R", which may be another alias.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:01:18 UTC 2024 - 5.1K bytes - Viewed (0) -
src/go/types/typexpr.go
// and so it must be resolved during type-checking so that we can report // errors. check.recordInstance(ix.Orig, inst.TypeArgs().list(), inst) if check.validateTArgLen(ix.Pos(), inst.obj.name, inst.TypeParams().Len(), inst.TypeArgs().Len()) { if i, err := check.verify(ix.Pos(), inst.TypeParams().list(), inst.TypeArgs().list(), check.context()); err != nil { // best position for error reporting pos := ix.Pos()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 16.3K bytes - Viewed (0) -
src/cmd/compile/internal/types2/named.go
// t must not have type arguments. func (t *Named) SetTypeParams(tparams []*TypeParam) { assert(t.inst == nil) t.resolve().tparams = bindTParams(tparams) } // TypeArgs returns the type arguments used to instantiate the named type t. func (t *Named) TypeArgs() *TypeList { if t.inst == nil { return nil } return t.inst.targs } // NumMethods returns the number of explicit methods defined for t.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 15 20:03:31 UTC 2024 - 23.9K bytes - Viewed (0) -
src/go/types/named.go
// t must not have type arguments. func (t *Named) SetTypeParams(tparams []*TypeParam) { assert(t.inst == nil) t.resolve().tparams = bindTParams(tparams) } // TypeArgs returns the type arguments used to instantiate the named type t. func (t *Named) TypeArgs() *TypeList { if t.inst == nil { return nil } return t.inst.targs } // NumMethods returns the number of explicit methods defined for t.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 15 20:03:31 UTC 2024 - 24K bytes - Viewed (0) -
src/cmd/compile/internal/types2/typexpr.go
// and so it must be resolved during type-checking so that we can report // errors. check.recordInstance(x, inst.TypeArgs().list(), inst) if check.validateTArgLen(x.Pos(), inst.obj.name, inst.TypeParams().Len(), inst.TypeArgs().Len()) { if i, err := check.verify(x.Pos(), inst.TypeParams().list(), inst.TypeArgs().list(), check.context()); err != nil { // best position for error reporting pos := x.Pos() if i < len(xlist) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 16.6K bytes - Viewed (0)