- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 20 for tabwidth (2.2 sec)
-
src/text/tabwriter/tabwriter.go
// padding is done with tabs if b.tabwidth == 0 { return // tabs have no width - can't do any padding } // make cellw the smallest multiple of b.tabwidth cellw = (cellw + b.tabwidth - 1) / b.tabwidth * b.tabwidth n := cellw - textw // amount of padding if n < 0 { panic("internal error") } b.writeN(tabs, (n+b.tabwidth-1)/b.tabwidth) return }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 29 16:46:34 UTC 2024 - 17.8K bytes - Viewed (0) -
src/go/printer/printer_test.go
// filter exports if necessary if mode&export != 0 { ast.FileExports(f) // ignore result f.Comments = nil // don't print comments that are not in AST } // determine printer configuration cfg := Config{Tabwidth: tabwidth} if mode&rawFormat != 0 { cfg.Mode |= RawFormat } if mode&normNumber != 0 { cfg.Mode |= normalizeNumbers } // print AST var buf bytes.Buffer
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 03 14:56:25 UTC 2024 - 20.4K bytes - Viewed (0) -
src/text/tabwriter/tabwriter_test.go
} } func check(t *testing.T, testname string, minwidth, tabwidth, padding int, padchar byte, flags uint, src, expected string) { var b buffer b.init(1000) var w Writer w.Init(&b, minwidth, tabwidth, padding, padchar, flags) // write all at once title := testname + " (written all at once)" b.clear() write(t, title, &w, src)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 29 16:46:34 UTC 2024 - 13.8K bytes - Viewed (0) -
src/cmd/gofmt/gofmt.go
} } ast.SortImports(fileSet, file) if *simplifyAST { simplify(file) } res, err := format(fileSet, file, sourceAdj, indentAdj, src, printer.Config{Mode: printerMode, Tabwidth: tabWidth}) if err != nil { return err } if !bytes.Equal(src, res) { // formatting has changed if *list { fmt.Fprintln(r, filename) } if *write { if info == nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue May 14 19:41:17 UTC 2024 - 15.1K bytes - Viewed (0) -
src/cmd/cgo/out.go
"internal/xcoff" "io" "os" "os/exec" "path/filepath" "regexp" "sort" "strings" "unicode" ) var ( conf = printer.Config{Mode: printer.SourcePos, Tabwidth: 8} noSourceConf = printer.Config{Tabwidth: 8} ) // writeDefs creates output files to be compiled by gc and gcc. func (p *Package) writeDefs() { var fgo2, fc io.Writer f := creat(*objDir + "_cgo_gotypes.go") defer f.Close()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Mar 29 16:41:10 UTC 2024 - 59.6K bytes - Viewed (0) -
internal/bpool/bpool.go
func NewBytePoolCap(maxSize uint64, width int, capwidth int) (bp *BytePoolCap) { if capwidth > 0 && capwidth < 64 { panic("buffer capped with smaller than 64 bytes is not supported") } if capwidth > 0 && width > capwidth { panic("buffer length cannot be > capacity of the buffer") } return &BytePoolCap{ c: make(chan []byte, maxSize), w: width, wcap: capwidth, } }
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Fri Apr 19 16:44:59 UTC 2024 - 2.6K bytes - Viewed (0) -
operator/pkg/util/progress/progress.go
// If we aren't a terminal, no need to spam extra lines prefix = `{{ yellow "-" }} ` } // reduce by 2 to allow for the "- " that will be added below maxWidth -= 2 if maxWidth > 0 && len(msg) > maxWidth { return prefix + msg[:maxWidth-3] + "..." } // cycle will alternate between "-" and " ". "-" is given multiple times to avoid quick flashing back and forth return prefix + msg } // For testing only
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue May 14 19:23:44 UTC 2024 - 6.2K bytes - Viewed (0) -
src/cmd/compile/internal/types/size.go
t.SetNotInHeap(true) } } offset += f.Type.width maxwidth := MaxWidth // On 32-bit systems, reflect tables impose an additional constraint // that each field start offset must fit in 31 bits. if maxwidth < 1<<32 { maxwidth = 1<<31 - 1 } if offset >= maxwidth { base.ErrorfAt(typePos(t), 0, "type %L too large", t) offset = 8 // small but nonzero } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 25 19:53:03 UTC 2024 - 15K bytes - Viewed (0) -
src/runtime/vdso_linux_amd64.go
package runtime import _ "unsafe" // for linkname const ( // vdsoArrayMax is the byte-size of a maximally sized array on this architecture. // See cmd/compile/internal/amd64/galign.go arch.MAXWIDTH initialization. vdsoArrayMax = 1<<50 - 1 ) var vdsoLinuxVersion = vdsoVersionKey{"LINUX_2.6", 0x3ae75f6} var vdsoSymbolKeys = []vdsoSymbolKey{ {"__vdso_gettimeofday", 0x315ca59, 0xb01bca00, &vdsoGettimeofdaySym},
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 15 19:57:43 UTC 2024 - 816 bytes - Viewed (0) -
src/cmd/compile/internal/ssa/export_test.go
return d.f } var testTypes Types func init() { // TODO(mdempsky): Push into types.InitUniverse or typecheck.InitUniverse. types.PtrSize = 8 types.RegSize = 8 types.MaxWidth = 1 << 50 base.Ctxt = &obj.Link{Arch: &obj.LinkArch{Arch: &sys.Arch{Alignment: 1, CanMergeLoads: true}}} typecheck.InitUniverse() testTypes.SetTypPtrs()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 20 21:19:39 UTC 2024 - 3.2K bytes - Viewed (0)