- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 97 for typechecker (1.09 sec)
-
src/go/types/errors.go
} } if check.conf._Trace { check.trace(err.posn().Pos(), "ERROR: %s (code = %d)", err.desc[0].msg, err.code) } // In go/types, if there is a sub-error with a valid position, // call the typechecker error handler for each sub-error. // Otherwise, call it once, with a single combined message. multiError := false if !isTypes2 { for i := 1; i < len(err.desc); i++ { if err.desc[i].posn.Pos().IsValid() {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 29 22:06:18 UTC 2024 - 8.5K bytes - Viewed (0) -
src/cmd/compile/internal/types2/errors.go
return } } if check.conf.Trace { check.trace(err.pos(), "ERROR: %s (code = %d)", err.desc[0].msg, err.code) } // In go/types, if there is a sub-error with a valid position, // call the typechecker error handler for each sub-error. // Otherwise, call it once, with a single combined message. multiError := false if !isTypes2 { for i := 1; i < len(err.desc); i++ { if err.desc[i].pos.IsKnown() {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 29 22:06:18 UTC 2024 - 6.6K bytes - Viewed (0) -
src/cmd/compile/internal/walk/range.go
// v1 = hv1t body = append(body, rangeAssign(nrange, hv1t)) } } } typecheck.Stmts(init) nfor.PtrInit().Append(init...) typecheck.Stmts(nfor.Cond.Init()) nfor.Cond = typecheck.Expr(nfor.Cond) nfor.Cond = typecheck.DefaultLit(nfor.Cond, nil) nfor.Post = typecheck.Stmt(nfor.Post) typecheck.Stmts(body) nfor.Body.Append(body...) nfor.Body.Append(nrange.Body...)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Sep 20 14:52:33 UTC 2023 - 17.6K bytes - Viewed (0) -
src/go/types/issues_test.go
const src = ` package p func f[T any]() {} func _() { f() } ` // no error handler provided (this issue) var conf Config typecheck(src, &conf, nil) // must not panic // with error handler (sanity check) conf.Error = func(error) {} typecheck(src, &conf, nil) // must not panic } func TestIssue63260(t *testing.T) { const src = ` package p func _() { use(f[*string])
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 28.1K bytes - Viewed (0) -
src/cmd/compile/internal/walk/switch.go
nif.Cond = typecheck.Expr(nif.Cond) nif.Cond = typecheck.DefaultLit(nif.Cond, nil) out.Append(nif) out = &nif.Else } return } half := lo + n/2 nif := ir.NewIfStmt(base.Pos, nil, nil, nil) nif.Cond = less(half) base.Pos = base.Pos.WithNotStmt() nif.Cond = typecheck.Expr(nif.Cond) nif.Cond = typecheck.DefaultLit(nif.Cond, nil)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 04 17:34:01 UTC 2024 - 30.1K bytes - Viewed (0) -
src/cmd/compile/internal/types2/issues_test.go
const src = ` package p func f[T any]() {} func _() { f() } ` // no error handler provided (this issue) var conf Config typecheck(src, &conf, nil) // must not panic // with error handler (sanity check) conf.Error = func(error) {} typecheck(src, &conf, nil) // must not panic } func TestIssue63260(t *testing.T) { const src = ` package p func _() { use(f[*string])
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 28.1K bytes - Viewed (0) -
src/cmd/compile/internal/types2/resolver.go
var obj Object for _, scope := range fileScopes { if scope.Contains(ident.Pos()) { obj = scope.Lookup(ident.Value) } } // If Config.go115UsesCgo is set, the typechecker will resolve Cgo // selectors to their cgo name. We must do the same here. if pname, _ := obj.(*PkgName); pname != nil { if pname.imported.cgo { // only set if Config.go115UsesCgo is set
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Apr 18 14:10:44 UTC 2024 - 26.3K bytes - Viewed (0) -
src/go/types/resolver.go
var obj Object for _, scope := range fileScopes { if scope.Contains(ident.Pos()) { obj = scope.Lookup(ident.Name) } } // If Config.go115UsesCgo is set, the typechecker will resolve Cgo // selectors to their cgo name. We must do the same here. if pname, _ := obj.(*PkgName); pname != nil { if pname.imported.cgo { // only set if Config.go115UsesCgo is set
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 17 16:22:59 UTC 2024 - 26.1K bytes - Viewed (0) -
src/go/types/builtins.go
} x.mode = value x.typ = NewPointer(universeByte) if check.recordTypes() { check.recordBuiltinType(call.Fun, makeSig(x.typ, Typ[String])) } case _Assert: // assert(pred) causes a typechecker error if pred is false. // The result of assert is the value of pred if there is no error. // Note: assert is only available in self-test mode. if x.mode != constant_ || !isBoolean(x.typ) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 27.2K bytes - Viewed (0) -
src/cmd/compile/internal/types2/builtins.go
} x.mode = value x.typ = NewPointer(universeByte) if check.recordTypes() { check.recordBuiltinType(call.Fun, makeSig(x.typ, Typ[String])) } case _Assert: // assert(pred) causes a typechecker error if pred is false. // The result of assert is the value of pred if there is no error. // Note: assert is only available in self-test mode. if x.mode != constant_ || !isBoolean(x.typ) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 27.1K bytes - Viewed (0)