Search Options

Results per page
Sort
Preferred Languages
Advance

Results 111 - 120 of 252 for Complex128 (0.14 sec)

  1. src/encoding/gob/encgen.go

    	},
    	{
    		"complex64",
    		"Complex64",
    		"0+0i",
    		`rpart := floatBits(float64(real(x)))
    		ipart := floatBits(float64(imag(x)))
    		state.encodeUint(rpart)
    		state.encodeUint(ipart)`,
    	},
    	{
    		"complex128",
    		"Complex128",
    		"0+0i",
    		`rpart := floatBits(real(x))
    		ipart := floatBits(imag(x))
    		state.encodeUint(rpart)
    		state.encodeUint(ipart)`,
    	},
    	{
    		"float32",
    		"Float32",
    		"0",
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 22 16:39:09 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  2. src/text/template/parse/parse_test.go

    		}
    		if test.isComplex {
    			if !n.IsComplex {
    				t.Errorf("expected complex for %q", test.text)
    			}
    			if n.Complex128 != test.complex128 {
    				t.Errorf("complex128 for %q should be %g Is %g", test.text, test.complex128, n.Complex128)
    			}
    		} else if n.IsComplex {
    			t.Errorf("did not expect complex for %q", test.text)
    		}
    	}
    }
    
    type parseTest struct {
    	name   string
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Feb 24 21:59:12 UTC 2024
    - 24K bytes
    - Viewed (0)
  3. src/runtime/testdata/testprog/panicprint.go

    // Copyright 2020 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package main
    
    type MyBool bool
    type MyComplex128 complex128
    type MyComplex64 complex64
    type MyFloat32 float32
    type MyFloat64 float64
    type MyInt int
    type MyInt8 int8
    type MyInt16 int16
    type MyInt32 int32
    type MyInt64 int64
    type MyString string
    type MyUint uint
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 08 19:10:41 UTC 2024
    - 2.2K bytes
    - Viewed (0)
  4. src/encoding/gob/codec_test.go

    		execDec(instr, state, t, reflect.ValueOf(&data))
    		if data != 17+19i {
    			t.Errorf("complex a = %v not 17+19i", data)
    		}
    	}
    
    	// complex128
    	{
    		var data complex128
    		instr := &decInstr{decOpTable[reflect.Complex128], 6, nil, ovfl}
    		state := newDecodeStateFromData(complexResult)
    		execDec(instr, state, t, reflect.ValueOf(&data))
    		if data != 17+19i {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Aug 19 23:03:14 UTC 2023
    - 36.9K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/typecheck/_builtin/runtime.go

    func int64tofloat32(int64) float32
    func uint64tofloat64(uint64) float64
    func uint64tofloat32(uint64) float32
    func uint32tofloat64(uint32) float64
    
    func complex128div(num complex128, den complex128) (quo complex128)
    
    func getcallerpc() uintptr
    func getcallersp() uintptr
    
    // race detection
    func racefuncenter(uintptr)
    func racefuncexit()
    func raceread(uintptr)
    func racewrite(uintptr)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 21 21:08:03 UTC 2024
    - 10.6K bytes
    - Viewed (0)
  6. src/internal/types/testdata/check/typeparams.go

    var _ = f4 /* ERROR "cannot infer C" */ (1, 2)
    var _ = f4[int, float32, complex128](1, 2)
    
    func f5[A, B, C any](A, []*B, struct{f []C}) int { panic(0) }
    
    var _ = f5[int, float32, complex128](0, nil, struct{f []complex128}{})
    var _ = f5 /* ERROR "cannot infer" */ (0, nil, struct{f []complex128}{})
    var _ = f5(0, []*float32{new[float32]()}, struct{f []complex128}{})
    
    func f6[A any](A, []A) int { panic(0) }
    
    var _ = f6(0, nil)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 19 01:56:58 UTC 2023
    - 15.2K bytes
    - Viewed (0)
  7. test/makechan.go

    	sink = make(T, float64(1.0)) // ERROR "non-integer buffer argument in make.*|must be integer"
    	sink = make(T, 1+0i)
    	sink = make(T, complex64(1+0i))  // ERROR "non-integer buffer argument in make.*|must be integer"
    	sink = make(T, complex128(1+0i)) // ERROR "non-integer buffer argument in make.*|must be integer"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 14:29:45 UTC 2024
    - 1K bytes
    - Viewed (0)
  8. src/runtime/error.go

    	case abi.Float64:
    		print(typestring, "(", *(*float64)(eface.data), ")")
    	case abi.Complex64:
    		print(typestring, *(*complex64)(eface.data))
    	case abi.Complex128:
    		print(typestring, *(*complex128)(eface.data))
    	default:
    		print("(", typestring, ") ", eface.data)
    	}
    }
    
    // printindented prints s, replacing "\n" with "\n\t".
    func printindented(s string) {
    	for {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 08 19:10:41 UTC 2024
    - 9.9K bytes
    - Viewed (0)
  9. test/maplinear.go

    		m := map[complex64]int{}
    		for i := 0; i < n; i++ {
    			m[complex(float32(i), float32(i))] = 1
    		}
    	})
    
    	// ~32ms on a 1.6GHz Zeon.
    	checkLinear("complex128", 10000, func(n int) {
    		m := map[complex128]int{}
    		for i := 0; i < n; i++ {
    			m[complex(float64(i), float64(i))] = 1
    		}
    	})
    
    	// ~70ms on a 1.6GHz Zeon.
    	// The iterate/delete idiom currently takes expected
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:25 UTC 2023
    - 3.6K bytes
    - Viewed (0)
  10. src/cmd/compile/internal/types2/universe.go

    	Float32:       {Float32, IsFloat, "float32"},
    	Float64:       {Float64, IsFloat, "float64"},
    	Complex64:     {Complex64, IsComplex, "complex64"},
    	Complex128:    {Complex128, IsComplex, "complex128"},
    	String:        {String, IsString, "string"},
    	UnsafePointer: {UnsafePointer, 0, "Pointer"},
    
    	UntypedBool:    {UntypedBool, IsBoolean | IsUntyped, "untyped bool"},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 9.1K bytes
    - Viewed (0)
Back to top