- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 23 for gofmt (0.34 sec)
-
src/cmd/go/internal/toolchain/select.go
// Setting pkg/tool before bin/go avoids that ordering problem. // The only other tool the go command invokes is gofmt, // so we set that one explicitly before handling bin (which will include bin/go). allowExec(filepath.Join(dir, "pkg/tool")) allowExec(filepath.Join(dir, "bin/gofmt")) allowExec(filepath.Join(dir, "bin")) } } srcUGoMod := filepath.Join(dir, "src/_go.mod")
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue May 07 17:25:05 UTC 2024 - 23.4K bytes - Viewed (0) -
build/root/Makefile
# # Args: # BRANCH: Branch to be passed to verify-vendor.sh script. # WHAT: List of checks to run # # Example: # make verify # make verify BRANCH=branch_x # make verify WHAT="gofmt typecheck" endef .PHONY: verify ifeq ($(PRINT_HELP),y) verify: echo "$$VERIFY_HELP_INFO" else ifeq ($(origin KUBE_VERIFY_GIT_BRANCH), undefined) verify:
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat Jun 01 16:43:08 UTC 2024 - 15.8K bytes - Viewed (0) -
src/cmd/go/alldocs.go
// // See also: go fmt, go vet. // // # Gofmt (reformat) package sources // // Usage: // // go fmt [-n] [-x] [packages] // // Fmt runs the command 'gofmt -l -w' on the packages named // by the import paths. It prints the names of the files that are modified. // // For more about gofmt, see 'go doc cmd/gofmt'. // For more about specifying packages, see 'go help packages'. //
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jun 11 16:54:28 UTC 2024 - 142.4K bytes - Viewed (0) -
src/os/exec/exec_test.go
} func TestAbsPathExec(t *testing.T) { testenv.MustHaveExec(t) testenv.MustHaveGoBuild(t) // must have GOROOT/bin/gofmt, but close enough // A simple exec of a full path should work. // Go 1.22 broke this on Windows, requiring ".exe"; see #66586. exe := filepath.Join(testenv.GOROOT(t), "bin/gofmt") cmd := exec.Command(exe) if cmd.Path != exe { t.Errorf("exec.Command(%#q) set Path=%#q", exe, cmd.Path) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Jun 07 20:13:53 UTC 2024 - 48.4K bytes - Viewed (0) -
src/cmd/cgo/gcc.go
error_(r.Pos(), "must call C.%s", fixGo(r.Name.Go)) } } return expr } // gofmtPos returns the gofmt-formatted string for an AST node, // with a comment setting the position before the node. func gofmtPos(n ast.Expr, pos token.Pos) string { s := gofmt(n) p := fset.Position(pos) if p.Column == 0 { return s } return fmt.Sprintf("/*line :%d:%d*/%s", p.Line, p.Column, s) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 20 15:50:06 UTC 2024 - 97K bytes - Viewed (0) -
src/go/token/position.go
// // With better compiler optimizations, this may not be needed in the // future, but at the moment this change improves the go/printer // benchmark performance by ~30%. This has a direct impact on the // speed of gofmt and thus seems worthwhile (2011-04-29). // TODO(gri): Remove this when compilers have caught up. i, j := 0, len(a) for i < j { h := int(uint(i+j) >> 1) // avoid overflow when computing h // i ≤ h < j
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 19.7K bytes - Viewed (0) -
src/go/doc/example.go
copy(imps, origImps) // Assume the imports are sorted by position. slices.SortFunc(imps, func(a, b *ast.ImportSpec) int { return cmp.Compare(a.Pos(), b.Pos()) }) // Assume gofmt has been applied, so there is a blank line between adjacent imps // if and only if they are more than 2 positions apart (newline, tab). var groupStarts []*ast.ImportSpec prevEnd := token.Pos(-2) for _, imp := range imps {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 21.4K bytes - Viewed (0) -
src/cmd/dist/build.go
checkNotStale(toolenv(), goBootstrap, toolchain...) copyfile(pathf("%s/compile4", tooldir), pathf("%s/compile", tooldir), writeExec) } // Check that there are no new files in $GOROOT/bin other than // go and gofmt and $GOOS_$GOARCH (target bin when cross-compiling). binFiles, err := filepath.Glob(pathf("%s/bin/*", goroot)) if err != nil { fatalf("glob: %v", err) } ok := map[string]bool{}
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 20 18:34:40 UTC 2024 - 54K bytes - Viewed (0) -
src/cmd/cover/cover.go
fmt.Fprintf(w, "}\n") } // It is possible for positions to repeat when there is a line // directive that does not specify column information and the input // has not been passed through gofmt. // See issues #27530 and #30746. // Tests are TestHtmlUnformatted and TestLineDup. // We use a map to avoid duplicates. // pos2 is a pair of token.Position values, used as a map key type. type pos2 struct {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue May 14 19:41:17 UTC 2024 - 34.5K bytes - Viewed (0) -
pkg/features/kube_features.go
// To add a new feature, define a key for it above and add it here. The features will be // available throughout Kubernetes binaries. // // Entries are separated from each other with blank lines to avoid sweeping gofmt changes // when adding or removing one entry. var defaultKubernetesFeatureGates = map[featuregate.Feature]featuregate.FeatureSpec{ CrossNamespaceVolumeDataSource: {Default: false, PreRelease: featuregate.Alpha},
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Wed Jun 12 22:51:23 UTC 2024 - 45.2K bytes - Viewed (0)