- Sort Score
- Result 10 results
- Languages All
Results 81 - 90 of 151 for dtoi (0.04 sec)
-
test/typeparam/settable.go
results[i].Set(v) } return results } // Two concrete types with the appropriate Set method. type SettableInt int func (p *SettableInt) Set(s string) { i, err := strconv.Atoi(s) if err != nil { panic(err) } *p = SettableInt(i) } type SettableString struct { s string } func (x *SettableString) Set(s string) { x.s = s } func main() {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 23:48:58 UTC 2022 - 2.7K bytes - Viewed (0) -
src/math/rand/default_test.go
// calls to top-level functions and to Seed without any duplicate values. // This will also give the race detector a change to report any problems. func doDefaultTest(t *testing.T, v string) { code, err := strconv.Atoi(v) if err != nil { t.Fatalf("internal error: unrecognized code %q", v) } goroutines := runtime.GOMAXPROCS(0) if goroutines < 4 { goroutines = 4 } ch := make(chan uint64, goroutines*3)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Feb 07 23:39:35 UTC 2023 - 3.4K bytes - Viewed (0) -
pilot/pkg/xds/pushqueue_test.go
for configkey := range request.ConfigsUpdated { updated = append(updated, fmt.Sprintf("%d", configkey.Kind)) } sort.Slice(updated, func(i, j int) bool { l, _ := strconv.Atoi(updated[i]) r, _ := strconv.Atoi(updated[j]) return l < r }) processed = append(processed, updated...) if len(processed) == 100 { done <- struct{}{} } p.MarkDone(con) } }()
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue Apr 30 00:26:45 UTC 2024 - 8.8K bytes - Viewed (0) -
src/cmd/go/testdata/script/test_fuzz_fuzztime.txt
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 01 20:09:52 UTC 2024 - 3.1K bytes - Viewed (0) -
src/internal/fuzz/pcg.go
state uint64 inc uint64 } func godebugSeed() *int { debug := strings.Split(os.Getenv("GODEBUG"), ",") for _, f := range debug { if strings.HasPrefix(f, "fuzzseed=") { seed, err := strconv.Atoi(strings.TrimPrefix(f, "fuzzseed=")) if err != nil { panic("malformed fuzzseed") } return &seed } } return nil } // newPcgRand generates a new, seeded Rand, ready for use.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 08 19:28:14 UTC 2024 - 3.3K bytes - Viewed (0) -
src/runtime/testdata/testprog/numcpu_freebsd.go
return fmt.Errorf("fail to launch child '%s', error: %s, output: %s", cmdline, err, output) } // NumCPU from FreeBSDNumCPUHelper come with '\n'. output = bytes.TrimSpace(output) n, err := strconv.Atoi(string(output)) if err != nil { return fmt.Errorf("fail to parse output from child '%s', error: %s, output: %s", cmdline, err, output) } if n != len(list) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Sep 30 20:09:46 UTC 2022 - 3.4K bytes - Viewed (0) -
src/net/http/triv.go
ctr.mu.Lock() defer ctr.mu.Unlock() switch req.Method { case "GET": ctr.n++ case "POST": var buf strings.Builder io.Copy(&buf, req.Body) body := buf.String() if n, err := strconv.Atoi(body); err != nil { fmt.Fprintf(w, "bad POST: %v\nbody: [%v]\n", err, body) } else { ctr.n = n fmt.Fprint(w, "counter reset\n") } } fmt.Fprintf(w, "counter = %d\n", ctr.n) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jan 10 03:29:50 UTC 2024 - 3.2K bytes - Viewed (0) -
docs/debugging/pprofgoparser/main.go
ret[t] = append(ret[t], stackTrace) } case record: save(line) default: z := goroutinesRE.FindStringSubmatch(line) if len(z) == 3 { if z[2] != "" { a, _ := strconv.Atoi(z[2]) t = time.Duration(a) * time.Minute save(line) record = true } else { skip = true } } } } return ret, nil } const helpUsage = `
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Wed Mar 06 11:43:16 UTC 2024 - 3.4K bytes - Viewed (0) -
src/cmd/cgo/internal/testerrors/errors_test.go
cmd := exec.Command("go", "run", path("long_double_size.go")) out, err := cmd.CombinedOutput() if err != nil { t.Fatalf("%#q: %v:\n%s", strings.Join(cmd.Args, " "), err, out) } i, err := strconv.Atoi(strings.TrimSpace(string(out))) if err != nil { t.Fatalf("long_double_size.go printed invalid size: %s", out) } return i } func TestReportsTypeErrors(t *testing.T) { for _, file := range []string{
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 20 15:50:06 UTC 2024 - 4K bytes - Viewed (0) -
pkg/api/testing/compat/compatibility_tester.go
} // Get the key (and optional index) key := keys[0] index := -1 if matches := regexp.MustCompile(`^(.*)\[(\d+)\]$`).FindStringSubmatch(key); len(matches) > 0 { key = matches[1] index, _ = strconv.Atoi(matches[2]) } // Look up the value value, ok := data[key] if !ok { return nil, false, fmt.Errorf("no key %s found", key) } // Get the indexed value if an index is specified
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Sat Jul 20 22:26:16 UTC 2019 - 3.7K bytes - Viewed (0)