Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 331 for FLOAT64 (0.1 sec)

  1. src/go/types/example_test.go

    		`package main
    import "fmt"
    func main() {
    	freezing := FToC(-18)
    	fmt.Println(freezing, Boiling) }
    `,
    		`package main
    import "fmt"
    type Celsius float64
    func (c Celsius) String() string { return fmt.Sprintf("%g°C", c) }
    func FToC(f float64) Celsius { return Celsius(f - 32 / 9 * 5) }
    const Boiling Celsius = 100
    func Unused() { {}; {{ var x int; _ = x }} } // make sure empty block scopes get printed
    `,
    	} {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 8.9K bytes
    - Viewed (0)
  2. src/cmd/trace/viewer.go

    		return traceviewer.GRunning
    	default:
    		panic(fmt.Sprintf("unknown GoState: %s", state.String()))
    	}
    }
    
    func viewerTime(t time.Duration) float64 {
    	return float64(t) / float64(time.Microsecond)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  3. schema/field.go

    			case uint:
    				field.ReflectValueOf(ctx, value).SetFloat(float64(data))
    			case uint8:
    				field.ReflectValueOf(ctx, value).SetFloat(float64(data))
    			case uint16:
    				field.ReflectValueOf(ctx, value).SetFloat(float64(data))
    			case uint32:
    				field.ReflectValueOf(ctx, value).SetFloat(float64(data))
    			case uint64:
    				field.ReflectValueOf(ctx, value).SetFloat(float64(data))
    			case []byte:
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Mon Apr 15 03:20:20 UTC 2024
    - 32K bytes
    - Viewed (0)
  4. src/log/slog/value.go

    	return time.Duration(int64(v.num))
    }
    
    // Float64 returns v's value as a float64. It panics
    // if v is not a float64.
    func (v Value) Float64() float64 {
    	if g, w := v.Kind(), KindFloat64; g != w {
    		panic(fmt.Sprintf("Value kind is %s, not %s", g, w))
    	}
    
    	return v.float()
    }
    
    func (v Value) float() float64 {
    	return math.Float64frombits(v.num)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 16 16:12:08 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  5. src/math/rand/v2/rand.go

    	if n == 0 {
    		panic("invalid argument to UintN")
    	}
    	return uint(r.uint64n(uint64(n)))
    }
    
    // Float64 returns, as a float64, a pseudo-random number in the half-open interval [0.0,1.0).
    func (r *Rand) Float64() float64 {
    	// There are exactly 1<<53 float64s in [0,1). Use Intn(1<<53) / (1<<53).
    	return float64(r.Uint64()<<11>>11) / (1 << 53)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 02:25:49 UTC 2024
    - 12.8K bytes
    - Viewed (0)
  6. pkg/kubelet/kuberuntime/kuberuntime_container_linux.go

    				memoryHigh = int64(math.Floor(
    					float64(memoryRequest)+
    						(float64(memoryLimit)-float64(memoryRequest))*float64(m.memoryThrottlingFactor))/float64(defaultPageSize)) * defaultPageSize
    			} else {
    				allocatable := m.getNodeAllocatable()
    				allocatableMemory, ok := allocatable[v1.ResourceMemory]
    				if ok && allocatableMemory.Value() > 0 {
    					memoryHigh = int64(math.Floor(
    						float64(memoryRequest)+
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 29 22:40:29 UTC 2024
    - 17.2K bytes
    - Viewed (0)
  7. cmd/warm-backend-minio.go

    		return
    	}
    
    	configuredPartSize := minPartSize
    	// Use floats for part size for all calculations to avoid
    	// overflows during float64 to int64 conversions.
    	partSizeFlt := float64(objectSize / maxPartsCount)
    	partSizeFlt = math.Ceil(partSizeFlt/float64(configuredPartSize)) * float64(configuredPartSize)
    
    	// Part size.
    	partSize = int64(partSizeFlt)
    	if partSize == 0 {
    		return minPartSize, nil
    	}
    	return partSize, nil
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Sun Apr 21 11:43:18 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/storage/cacher/metrics/metrics.go

    	listCacheNumReturned.WithLabelValues(resourcePrefix).Add(float64(numReturned))
    }
    
    // RecordResourceVersion sets the current resource version for a given resource type.
    func RecordResourceVersion(resourcePrefix string, resourceVersion uint64) {
    	watchCacheResourceVersion.WithLabelValues(resourcePrefix).Set(float64(resourceVersion))
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jun 07 07:39:23 UTC 2024
    - 7.5K bytes
    - Viewed (0)
  9. src/math/unsafe.go

    // and Float64bits(Float64frombits(x)) == x.
    func Float64bits(f float64) uint64 { return *(*uint64)(unsafe.Pointer(&f)) }
    
    // Float64frombits returns the floating-point number corresponding
    // to the IEEE 754 binary representation b, with the sign bit of b
    // and the result in the same bit position.
    // Float64frombits(Float64bits(x)) == x.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 1.6K bytes
    - Viewed (0)
  10. src/flag/flag_test.go

    	float64Flag := f.Float64("float64", 0, "float64 value")
    	durationFlag := f.Duration("duration", 5*time.Second, "time.Duration value")
    	extra := "one-extra-argument"
    	args := []string{
    		"-bool",
    		"-bool2=true",
    		"--int", "22",
    		"--int64", "0x23",
    		"-uint", "24",
    		"--uint64", "25",
    		"-string", "hello",
    		"-float64", "2718e28",
    		"-duration", "2m",
    		extra,
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 18:38:24 UTC 2024
    - 22K bytes
    - Viewed (0)
Back to top