- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 60 for posFor (0.12 sec)
-
src/go/printer/printer.go
var last *ast.Comment for p.commentBefore(next) { list := p.comment.List changed := false if p.lastTok != token.IMPORT && // do not rewrite cgo's import "C" comments p.posFor(p.comment.Pos()).Column == 1 && p.posFor(p.comment.End()+1) == next { // Unindented comment abutting next token position: // a top-level doc comment. list = formatDocComment(list) changed = true
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 19 12:02:03 UTC 2023 - 41.6K bytes - Viewed (0) -
src/go/printer/nodes.go
if len(list) == 0 { if isIncomplete { prev := p.posFor(prev0) next := p.posFor(next0) if prev.IsValid() && prev.Line == next.Line { p.print("/* " + filteredMsg + " */") } else { p.print(newline) p.print(indent, "// "+filteredMsg, unindent, newline) } } return } prev := p.posFor(prev0) next := p.posFor(next0) line := p.lineFor(list[0].Pos())
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Oct 17 18:53:17 UTC 2023 - 52.6K bytes - Viewed (0) -
src/errors/wrap_test.go
var poserPathErr = &fs.PathError{Op: "poser"} func (p *poser) Error() string { return p.msg } func (p *poser) Is(err error) bool { return p.f(err) } func (p *poser) As(err any) bool { switch x := err.(type) { case **poser: *x = p case *errorT: *x = errorT{"poser"} case **fs.PathError: *x = poserPathErr default: return false } return true } func TestAs(t *testing.T) { var errT errorT
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Apr 03 22:49:49 UTC 2024 - 6K bytes - Viewed (0) -
src/cmd/compile/internal/types2/errors.go
invalidOp = "invalid operation: " ) // The poser interface is used to extract the position of type-checker errors. type poser interface { Pos() syntax.Pos } func (check *Checker) error(at poser, code Code, msg string) { err := check.newError(code) err.addf(at, "%s", msg) err.report() } func (check *Checker) errorf(at poser, code Code, format string, args ...any) { err := check.newError(code)
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/types2/util.go
func hasDots(call *syntax.CallExpr) bool { return call.HasDots } // dddErrPos returns the node (poser) for reporting an invalid ... use in a call. func dddErrPos(call *syntax.CallExpr) *syntax.CallExpr { // TODO(gri) should use "..." instead of call position return call } // argErrPos returns the node (poser) for reporting an invalid argument count. func argErrPos(call *syntax.CallExpr) *syntax.CallExpr { return call }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:01:18 UTC 2024 - 2.1K bytes - Viewed (0) -
src/cmd/compile/internal/types2/version.go
// is allowed to use version v. If the position is unknown, the specified // module version (Config.GoVersion) is used. If that version is invalid, // allowVersion returns true. func (check *Checker) allowVersion(at poser, v goVersion) bool { fileVersion := check.conf.GoVersion if pos := at.Pos(); pos.IsKnown() { fileVersion = check.versions[pos.FileBase()] } // We need asGoVersion (which calls version.Lang) below
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 20 20:44:57 UTC 2024 - 2.4K bytes - Viewed (0) -
src/database/sql/fakedb_test.go
} if rc.closed { return errors.New("fakedb: cursor is closed") } rc.touchMem() rc.posRow++ if rc.posRow == rc.errPos { return rc.err } if rc.posRow >= len(rc.rows[rc.posSet]) { return io.EOF // per interface spec } for i, v := range rc.rows[rc.posSet][rc.posRow].cols { // TODO(bradfitz): convert to subset types? naah, I // think the subset types should only be input to
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Apr 01 12:38:07 UTC 2024 - 30.3K bytes - Viewed (0) -
src/runtime/os_openbsd_mips64.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Dec 05 20:34:30 UTC 2023 - 329 bytes - Viewed (0) -
src/runtime/os_freebsd_arm64.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Dec 05 20:34:30 UTC 2023 - 320 bytes - Viewed (0) -
src/internal/zstd/testdata/1890a371.gettysburg.txt-100x.zst
It is altogether fitting and proper that we should do this. But, in a larger sense, we can not dedicate - we can not consecrate - we can not hallow - this ground. The brave men, living and dead, who struggled here, have consecrated it, far above our poor power to add or detract. The world will little note, nor long remember what we say here, but it can never forget what they did here. It is for us the living, rather, to be dedicated here to the unfinished work which they who fought here have thus far...
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Sep 27 14:35:13 UTC 2023 - 826 bytes - Viewed (0)