Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 180 for maxint (0.11 sec)

  1. src/slices/slices_test.go

    		{x: make([]struct{}, math.MaxInt/6-5), count: 6, want: make([]struct{}, 6*(math.MaxInt/6-5))},
    		{x: make([]struct{}, math.MaxInt/7-6), count: 7, want: make([]struct{}, 7*(math.MaxInt/7-6))},
    		{x: make([]struct{}, math.MaxInt/8-7), count: 8, want: make([]struct{}, 8*(math.MaxInt/8-7))},
    		{x: make([]struct{}, math.MaxInt/9-8), count: 9, want: make([]struct{}, 9*(math.MaxInt/9-8))},
    	} {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 26 13:32:06 UTC 2024
    - 33.2K bytes
    - Viewed (0)
  2. src/encoding/base64/base64_test.go

    	switch strconv.IntSize {
    	case 32:
    		tests = append(tests, test{RawStdEncoding, (math.MaxInt-5)/8 + 1, 357913942})
    		tests = append(tests, test{RawStdEncoding, math.MaxInt/4*3 + 2, math.MaxInt})
    	case 64:
    		tests = append(tests, test{RawStdEncoding, (math.MaxInt-5)/8 + 1, 1537228672809129302})
    		tests = append(tests, test{RawStdEncoding, math.MaxInt/4*3 + 2, math.MaxInt})
    	}
    	for _, tt := range tests {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Sep 03 18:57:29 UTC 2023
    - 15.9K bytes
    - Viewed (0)
  3. src/encoding/base32/base32_test.go

    	switch strconv.IntSize {
    	case 32:
    		tests = append(tests, test{rawStdEncoding, (math.MaxInt-4)/8 + 1, 429496730})
    		tests = append(tests, test{rawStdEncoding, math.MaxInt/8*5 + 4, math.MaxInt})
    	case 64:
    		tests = append(tests, test{rawStdEncoding, (math.MaxInt-4)/8 + 1, 1844674407370955162})
    		tests = append(tests, test{rawStdEncoding, math.MaxInt/8*5 + 4, math.MaxInt})
    	}
    	for _, tt := range tests {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 16:25:54 UTC 2024
    - 26K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/ssa/loopbce.go

    					v := limit.AuxInt
    					if !inclusive {
    						if v == maxSignedValue(limit.Type) {
    							return false // > maxint is never satisfiable.
    						}
    						v++
    					}
    					if init.isGenericIntConst() {
    						// Use stride to compute a better lower limit.
    						if init.AuxInt < v {
    							return false
    						}
    						v = subU(init.AuxInt, diff(init.AuxInt, v)/uint64(-step)*uint64(-step))
    					}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Nov 07 17:37:47 UTC 2023
    - 11.8K bytes
    - Viewed (0)
  5. src/slices/slices.go

    // overflows.
    func Repeat[S ~[]E, E any](x S, count int) S {
    	if count < 0 {
    		panic("cannot be negative")
    	}
    
    	const maxInt = ^uint(0) >> 1
    	if hi, lo := bits.Mul(uint(len(x)), uint(count)); hi > 0 || lo > maxInt {
    		panic("the result of (len(x) * count) overflows")
    	}
    
    	newslice := make(S, len(x)*count)
    	n := copy(newslice, x)
    	for n < len(newslice) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 29 14:01:59 UTC 2024
    - 13.6K bytes
    - Viewed (0)
  6. src/strings/strings.go

    	case 0:
    		return ""
    	case 1:
    		return elems[0]
    	}
    
    	var n int
    	if len(sep) > 0 {
    		if len(sep) >= maxInt/(len(elems)-1) {
    			panic("strings: Join output length overflow")
    		}
    		n += len(sep) * (len(elems) - 1)
    	}
    	for _, elem := range elems {
    		if len(elem) > maxInt-n {
    			panic("strings: Join output length overflow")
    		}
    		n += len(elem)
    	}
    
    	var b Builder
    	b.Grow(n)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 16:48:16 UTC 2024
    - 31.2K bytes
    - Viewed (0)
  7. src/bytes/buffer_test.go

    		if err := recover(); err != ErrTooLarge {
    			t.Errorf("after too-large Grow, recover() = %v; want %v", err, ErrTooLarge)
    		}
    	}()
    
    	buf := NewBuffer(make([]byte, 1))
    	const maxInt = int(^uint(0) >> 1)
    	buf.Grow(maxInt)
    }
    
    // Was a bug: used to give EOF reading empty slice at EOF.
    func TestReadEmptyAtEOF(t *testing.T) {
    	b := new(Buffer)
    	slice := make([]byte, 0)
    	n, err := b.Read(slice)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 26 13:31:36 UTC 2024
    - 18.6K bytes
    - Viewed (0)
  8. pkg/webhooks/validation/controller/controller.go

    	}
    
    	c.queue = controllers.NewQueue("validation",
    		controllers.WithReconciler(c.Reconcile),
    		// Webhook patching has to be retried forever. But the retries would be rate limited.
    		controllers.WithMaxAttempts(math.MaxInt),
    		// Retry with backoff. Failures could be from conflicts of other instances (quick retry helps), or
    		// longer lasting concerns which will eventually be retried on 1min interval.
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 28 16:52:19 UTC 2024
    - 11.3K bytes
    - Viewed (0)
  9. src/net/tcpsock_test.go

    				}
    			}
    		}()
    	}
    	for i := 0; i < conns; i++ {
    		<-done
    	}
    	ln.Close()
    	<-done
    }
    
    // Test that >32-bit reads work on 64-bit systems.
    // On 32-bit systems this tests that maxint reads work.
    func TestTCPBig(t *testing.T) {
    	if !*testTCPBig {
    		t.Skip("test disabled; use -tcpbig to enable")
    	}
    
    	for _, writev := range []bool{false, true} {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Feb 20 06:04:31 UTC 2024
    - 17.7K bytes
    - Viewed (0)
  10. src/internal/trace/internal/oldtrace/parser.go

    		off := p.off - 1
    
    		pid, err := p.readVal()
    		if err != nil {
    			return err
    		}
    		if pid != math.MaxUint64 && pid > math.MaxInt32 {
    			return fmt.Errorf("processor ID %d is larger than maximum of %d", pid, uint64(math.MaxUint))
    		}
    
    		var pid32 int32
    		if pid == math.MaxUint64 {
    			pid32 = -1
    		} else {
    			pid32 = int32(pid)
    		}
    
    		v, err := p.readVal()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 21:15:28 UTC 2024
    - 46.8K bytes
    - Viewed (0)
Back to top