Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 935 for maxint (0.15 sec)

  1. src/internal/types/testdata/spec/range_int.go

    }
    
    func issue65133() {
    	for range maxInt {
    	}
    	for range maxInt /* ERROR "cannot use maxInt + 1 (untyped int constant 9223372036854775808) as int value in range clause (overflows)" */ + 1 {
    	}
    	for range maxUint /* ERROR "cannot use maxUint (untyped int constant 18446744073709551615) as int value in range clause (overflows)" */ {
    	}
    
    	for i := range maxInt {
    		_ = i
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 16 18:56:00 UTC 2024
    - 4.7K bytes
    - Viewed (0)
  2. api/go1.17.txt

    pkg math (linux-arm), const MaxInt = 2147483647
    pkg math (linux-arm), const MaxUint = 4294967295
    pkg math (linux-arm), const MinInt = -2147483648
    pkg math (linux-arm-cgo), const MaxInt = 2147483647
    pkg math (linux-arm-cgo), const MaxUint = 4294967295
    pkg math (linux-arm-cgo), const MinInt = -2147483648
    pkg math (netbsd-386), const MaxInt = 2147483647
    pkg math (netbsd-386), const MaxUint = 4294967295
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Feb 17 20:31:46 UTC 2023
    - 18K bytes
    - Viewed (0)
  3. src/internal/types/testdata/check/const1.go

    )
    
    const (
    	minInt8 = -1<<(8<<iota - 1)
    	minInt16
    	minInt32
    	minInt64
    	minInt = -1<<(8<<logSizeofInt - 1)
    )
    
    const (
    	maxInt8 = 1<<(8<<iota - 1) - 1
    	maxInt16
    	maxInt32
    	maxInt64
    	maxInt = 1<<(8<<logSizeofInt - 1) - 1
    )
    
    const (
    	maxUint8 = 1<<(8<<iota) - 1
    	maxUint16
    	maxUint32
    	maxUint64
    	maxUint    = 1<<(8<<logSizeofUint) - 1
    	maxUintptr = 1<<(8<<logSizeofUintptr) - 1
    )
    
    const (
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Oct 31 16:11:16 UTC 2023
    - 8.5K bytes
    - Viewed (0)
  4. src/internal/saferio/io_test.go

    		}
    	})
    
    	t.Run("large", func(t *testing.T) {
    		_, err := ReadData(bytes.NewReader(input), 10<<30)
    		if err == nil {
    			t.Error("large read succeeded unexpectedly")
    		}
    	})
    
    	t.Run("maxint", func(t *testing.T) {
    		_, err := ReadData(bytes.NewReader(input), 1<<62)
    		if err == nil {
    			t.Error("large read succeeded unexpectedly")
    		}
    	})
    
    	t.Run("small-EOF", func(t *testing.T) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 31 00:34:05 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  5. test/fixedbugs/issue29190.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package main
    
    import (
    	"strings"
    )
    
    type T struct{}
    
    const maxInt = int(^uint(0) >> 1)
    
    func main() {
    	s := make([]T, maxInt)
    	shouldPanic("len out of range", func() { s = append(s, T{}) })
    	var oneElem = make([]T, 1)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 08 16:58:57 UTC 2022
    - 707 bytes
    - Viewed (0)
  6. src/math/const_test.go

    	}
    }
    
    func TestMaxInt(t *testing.T) {
    	if v := int(MaxInt); v+1 != MinInt {
    		t.Errorf("MaxInt should wrap around to MinInt: %d", v+1)
    	}
    	if v := int8(MaxInt8); v+1 != MinInt8 {
    		t.Errorf("MaxInt8 should wrap around to MinInt8: %d", v+1)
    	}
    	if v := int16(MaxInt16); v+1 != MinInt16 {
    		t.Errorf("MaxInt16 should wrap around to MinInt16: %d", v+1)
    	}
    	if v := int32(MaxInt32); v+1 != MinInt32 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 03 22:44:33 UTC 2021
    - 1.3K bytes
    - Viewed (0)
  7. src/math/const.go

    const (
    	intSize = 32 << (^uint(0) >> 63) // 32 or 64
    
    	MaxInt    = 1<<(intSize-1) - 1  // MaxInt32 or MaxInt64 depending on intSize.
    	MinInt    = -1 << (intSize - 1) // MinInt32 or MinInt64 depending on intSize.
    	MaxInt8   = 1<<7 - 1            // 127
    	MinInt8   = -1 << 7             // -128
    	MaxInt16  = 1<<15 - 1           // 32767
    	MinInt16  = -1 << 15            // -32768
    	MaxInt32  = 1<<31 - 1           // 2147483647
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 21 14:07:39 UTC 2022
    - 2.8K bytes
    - Viewed (0)
  8. 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)
  9. src/internal/concurrent/hashtriemap_test.go

    				expectPresent(t, s, i)(m.Load(s))
    				expectLoaded(t, s, i)(m.LoadOrStore(s, 0))
    			}
    			for i, s := range testData {
    				expectPresent(t, s, i)(m.Load(s))
    				expectNotDeleted(t, s, math.MaxInt)(m.CompareAndDelete(s, math.MaxInt))
    				expectDeleted(t, s, i)(m.CompareAndDelete(s, i))
    				expectNotDeleted(t, s, i)(m.CompareAndDelete(s, i))
    				expectMissing(t, s, 0)(m.Load(s))
    			}
    			for _, s := range testData {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 16:01:55 UTC 2024
    - 9.3K bytes
    - Viewed (0)
  10. src/go/doc/testdata/b.0.golden

    		C5
    	)
    
    	// 
    	const C notExported = 0
    
    	// 
    	const Pi = 3.14	// Pi
    
    
    VARIABLES
    	// 
    	var (
    		U1, U2, U4, U5	notExported
    	
    		U7	notExported	= 7
    	)
    
    	// 
    	var MaxInt int	// MaxInt
    
    	// 
    	var V notExported
    
    	// 
    	var V1, V2, V4, V5 notExported
    
    
    FUNCTIONS
    	// Associated with comparable type if AllDecls is set. 
    	func ComparableFactory() comparable
    
    	// 
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Feb 11 16:05:02 UTC 2022
    - 766 bytes
    - Viewed (0)
Back to top