Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of about 10,000 for ctan (0.06 sec)

  1. src/math/atan.go

    		Tan3pio8 = 2.41421356237309504880      // tan(3*pi/8)
    	)
    	if x <= 0.66 {
    		return xatan(x)
    	}
    	if x > Tan3pio8 {
    		return Pi/2 - xatan(1/x) + Morebits
    	}
    	return Pi/4 + xatan((x-1)/(x+1)) + 0.5*Morebits
    }
    
    // Atan returns the arctangent, in radians, of x.
    //
    // Special cases are:
    //
    //	Atan(±0) = ±0
    //	Atan(±Inf) = ±Pi/2
    func Atan(x float64) float64 {
    	if haveArchAtan {
    		return archAtan(x)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 11 16:34:30 UTC 2022
    - 3K bytes
    - Viewed (0)
  2. src/go/types/chan.go

    func NewChan(dir ChanDir, elem Type) *Chan {
    	return &Chan{dir: dir, elem: elem}
    }
    
    // Dir returns the direction of channel c.
    func (c *Chan) Dir() ChanDir { return c.dir }
    
    // Elem returns the element type of channel c.
    func (c *Chan) Elem() Type { return c.elem }
    
    func (c *Chan) Underlying() Type { return c }
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 18:48:38 UTC 2024
    - 1K bytes
    - Viewed (0)
  3. src/runtime/chan.go

    	// instead of idx itself.  However, in a future version of this function,
    	// we can use idx to better handle the case of elemsize==0.
    	// A future improvement to the detector is to call TSan with c and idx:
    	// this way, Go will continue to not allocating buffer entries for channels
    	// of elemsize==0, yet the race detector can be made to handle multiple
    	// sync objects underneath the hood (one sync object per idx)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:16:50 UTC 2024
    - 25.9K bytes
    - Viewed (0)
  4. src/math/tan.go

    	-5.38695755929454629881e7, // 0xc189afe03cbe5a31
    }
    
    // Tan returns the tangent of the radian argument x.
    //
    // Special cases are:
    //
    //	Tan(±0) = ±0
    //	Tan(±Inf) = NaN
    //	Tan(NaN) = NaN
    func Tan(x float64) float64 {
    	if haveArchTan {
    		return archTan(x)
    	}
    	return tan(x)
    }
    
    func tan(x float64) float64 {
    	const (
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun May 08 17:27:54 UTC 2022
    - 3.7K bytes
    - Viewed (0)
  5. src/runtime/race/testdata/mop_test.go

    func TestRaceForTest(t *testing.T) {
    	done := make(chan bool)
    	c := make(chan bool)
    	stop := false
    	go func() {
    		for {
    			_, ok := <-c
    			if !ok {
    				done <- true
    				return
    			}
    			stop = true
    		}
    	}()
    	for !stop {
    		c <- true
    	}
    	close(c)
    	<-done
    }
    
    func TestRaceForIncr(t *testing.T) {
    	done := make(chan bool)
    	c := make(chan bool)
    	x := 0
    	go func() {
    		for {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 23 16:46:25 UTC 2023
    - 28.9K bytes
    - Viewed (0)
  6. test/typeparam/issue47901.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package main
    
    type Chan[T any] chan Chan[T]
    
    func (ch Chan[T]) recv() Chan[T] {
    	return <-ch
    }
    
    func main() {
    	ch := Chan[int](make(chan Chan[int]))
    	go func() {
    		ch <- make(Chan[int])
    	}()
    	ch.recv()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 01 19:45:34 UTC 2022
    - 372 bytes
    - Viewed (0)
  7. src/internal/types/testdata/fixedbugs/issue47115.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package p
    
    type C0 interface{ int }
    type C1 interface{ chan int }
    type C2 interface{ chan int | <-chan int }
    type C3 interface{ chan int | chan float32 }
    type C4 interface{ chan int | chan<- int }
    type C5[T any] interface{ ~chan T | chan<- T }
    
    func _[T any](ch T) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:54:27 UTC 2023
    - 840 bytes
    - Viewed (0)
  8. src/internal/types/testdata/fixedbugs/issue51229.go

    func ch1[P chan<- int]() (_ P)           { return } // core(P) == chan<- int   (single type, no tilde)
    func ch2[P ~chan int]()                  { return } // core(P) == ~chan<- int  (tilde)
    func ch3[P chan E, E any](E)             { return } // core(P) == chan<- E     (single type, no tilde)
    func ch4[P chan E | ~chan<- E, E any](E) { return } // core(P) == ~chan<- E    (tilde)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:54:27 UTC 2023
    - 4.8K bytes
    - Viewed (0)
  9. src/go/types/typestring_test.go

    	// maps
    	dup("map[string]int"),
    	{"map[struct{x, y int}][]byte", "map[struct{x int; y int}][]byte"},
    
    	// channels
    	dup("chan<- chan int"),
    	dup("chan<- <-chan int"),
    	dup("<-chan <-chan int"),
    	dup("chan (<-chan int)"),
    	dup("chan<- func()"),
    	dup("<-chan []func() int"),
    }
    
    // types that depend on other type declarations (src in TestTypes)
    var dependentTestTypes = []testEntry{
    	// interfaces
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 28 17:58:07 UTC 2023
    - 3.9K bytes
    - Viewed (0)
  10. pilot/pkg/server/instance.go

    	components chan task
    	done       chan struct{}
    
    	// requiredTerminations keeps track of tasks that should block instance exit
    	// if they are not stopped. This allows important cleanup tasks to be completed.
    	// Note: this is still best effort; a process can die at any time.
    	requiredTerminations sync.WaitGroup
    }
    
    func (i *instance) Start(stop <-chan struct{}) error {
    	shutdown := func() {
    		close(i.done)
    	}
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 4.6K bytes
    - Viewed (0)
Back to top