- Sort Score
- Result 10 results
- Languages All
Results 1 - 6 of 6 for collectTypeParams (0.29 sec)
-
src/cmd/compile/internal/types2/typeparam.go
case *Basic: if !isValid(u) { // error is reported elsewhere return &emptyInterface } case *Interface: if isTypeParam(bound) { // error is reported in Checker.collectTypeParams return &emptyInterface } ityp = u } // If we don't have an interface, wrap constraint into an implicit interface. if ityp == nil { ityp = NewInterfaceType(nil, []Type{bound})
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 15 20:03:31 UTC 2024 - 4.9K bytes - Viewed (0) -
src/go/types/typeparam.go
case *Basic: if !isValid(u) { // error is reported elsewhere return &emptyInterface } case *Interface: if isTypeParam(bound) { // error is reported in Checker.collectTypeParams return &emptyInterface } ityp = u } // If we don't have an interface, wrap constraint into an implicit interface. if ityp == nil { ityp = NewInterfaceType(nil, []Type{bound})
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 15 20:03:31 UTC 2024 - 5.1K bytes - Viewed (0) -
src/cmd/compile/internal/types2/decl.go
versionErr = true } check.openScope(tdecl, "type parameters") defer check.closeScope() check.collectTypeParams(&alias.tparams, tdecl.TParamList) } rhs = check.definedType(tdecl.Type, obj) assert(rhs != nil) alias.fromRHS = rhs Unalias(alias) // resolve alias.actual } else {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 29.6K bytes - Viewed (0) -
src/go/types/decl.go
versionErr = true } check.openScope(tdecl, "type parameters") defer check.closeScope() check.collectTypeParams(&alias.tparams, tdecl.TypeParams) } rhs = check.definedType(tdecl.Type, obj) assert(rhs != nil) alias.fromRHS = rhs Unalias(alias) // resolve alias.actual } else {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 31K bytes - Viewed (0) -
src/cmd/compile/internal/types2/signature.go
} } } if tparams != nil { // The parser will complain about invalid type parameters for methods. check.collectTypeParams(&sig.tparams, tparams) } // Use a temporary scope for all parameter declarations and then // squash that scope into the parent scope (and report any // redeclarations at that time). //
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 15 21:33:05 UTC 2024 - 12.6K bytes - Viewed (0) -
src/go/types/signature.go
got := measure(len(tparams), "type parameter") check.errorf(recvPar, BadRecv, "got %s, but receiver base type declares %d", got, len(recvTParams)) } } } if ftyp.TypeParams != nil { check.collectTypeParams(&sig.tparams, ftyp.TypeParams) // Always type-check method type parameters but complain that they are not allowed. // (A separate check is needed when type-checking interface method signatures because
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 29 22:06:18 UTC 2024 - 13K bytes - Viewed (0)