- Sort Score
- Result 10 results
- Languages All
Results 1 - 9 of 9 for IsPlusBuild (0.21 sec)
-
src/go/build/constraint/expr.go
} p.pos = p.i p.i += len(tag) p.tok = p.s[p.pos:p.i] p.isTag = true } // IsPlusBuild reports whether the line of text is a “// +build” constraint. // It only checks the prefix of the text, not that the expression itself parses. func IsPlusBuild(line string) bool { _, ok := splitPlusBuild(line) return ok }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 19 12:02:03 UTC 2023 - 14.2K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/analysis/passes/buildtag/buildtag.go
return } if check.goBuild == nil { check.goBuild = x } } func (check *checker) plusBuildLine(pos token.Pos, line string) { line = strings.TrimSpace(line) if !constraint.IsPlusBuild(line) { // Comment with +build but not at beginning. // Only report early in file. if check.plusBuildOK && !strings.HasPrefix(line, "// want") { check.pass.Reportf(pos, "possible malformed +build comment") }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 02:38:00 UTC 2024 - 9.3K bytes - Viewed (0) -
src/cmd/go/internal/imports/build.go
p = p[len(p):] } line = bytes.TrimSpace(line) if !bytes.HasPrefix(line, bSlashSlash) || !bytes.Contains(line, bPlusBuild) { continue } text := string(line) if !constraint.IsPlusBuild(text) { continue } if x, err := constraint.Parse(text); err == nil { if !eval(x, tags, true) { shouldBuild = false } } } } return shouldBuild }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 30 18:50:57 UTC 2023 - 10.4K bytes - Viewed (0) -
src/cmd/go/internal/modindex/build.go
p = p[len(p):] } line = bytes.TrimSpace(line) if !bytes.HasPrefix(line, bSlashSlash) || !bytes.Contains(line, bPlusBuild) { continue } text := string(line) if !constraint.IsPlusBuild(text) { continue } plusBuild = append(plusBuild, text) } } return string(goBuildBytes), plusBuild, sawBinaryOnly, nil }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Aug 25 17:39:23 UTC 2023 - 26.8K bytes - Viewed (0) -
src/go/printer/printer.go
p.indent = 0 } // shortcut common case of //-style comments if text[1] == '/' { if constraint.IsGoBuild(text) { p.goBuild = append(p.goBuild, len(p.output)) } else if constraint.IsPlusBuild(text) { p.plusBuild = append(p.plusBuild, len(p.output)) } p.writeString(pos, trimRight(text), true) return } // for /*-style comments, print line by line and let the
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/cmd/internal/testdir/testdir_test.go
var action string for actionSrc := src; action == "" && actionSrc != ""; { var line string line, actionSrc, _ = strings.Cut(actionSrc, "\n") if constraint.IsGoBuild(line) || constraint.IsPlusBuild(line) { continue } action = strings.TrimSpace(strings.TrimPrefix(line, "//")) } if action == "" { t.Fatalf("execution recipe not found in GOROOT/test/%s", t.goFileName()) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 21 20:08:06 UTC 2024 - 57.5K bytes - Viewed (0) -
src/go/build/build.go
p = p[len(p):] } line = bytes.TrimSpace(line) if !bytes.HasPrefix(line, slashSlash) || !bytes.Contains(line, plusBuild) { continue } text := string(line) if !constraint.IsPlusBuild(text) { continue } if x, err := constraint.Parse(text); err == nil { if !ctxt.eval(x, allTags) { shouldBuild = false } } } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 29 16:25:21 UTC 2024 - 62.3K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go
{"(*TagExpr).String", Method, 16}, {"AndExpr", Type, 16}, {"AndExpr.X", Field, 16}, {"AndExpr.Y", Field, 16}, {"Expr", Type, 16}, {"GoVersion", Func, 21}, {"IsGoBuild", Func, 16}, {"IsPlusBuild", Func, 16}, {"NotExpr", Type, 16}, {"NotExpr.X", Field, 16}, {"OrExpr", Type, 16}, {"OrExpr.X", Field, 16}, {"OrExpr.Y", Field, 16}, {"Parse", Func, 16}, {"PlusBuildLines", Func, 16},
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 02:20:05 UTC 2024 - 534.2K bytes - Viewed (0) -
api/go1.16.txt
pkg go/build, type Package struct, XTestEmbedPatterns []string pkg go/build, type Package struct, XTestEmbedPatternPos map[string][]token.Position pkg go/build/constraint, func IsGoBuild(string) bool pkg go/build/constraint, func IsPlusBuild(string) bool pkg go/build/constraint, func Parse(string) (Expr, error) pkg go/build/constraint, func PlusBuildLines(Expr) ([]string, error) pkg go/build/constraint, method (*AndExpr) Eval(func(string) bool) bool
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Dec 02 16:30:41 UTC 2022 - 479.2K bytes - Viewed (0)