- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of about 10,000 for ctan (0.48 sec)
-
src/runtime/race/testdata/comp_test.go
func TestNoRaceComp2(t *testing.T) { c := make(chan bool, 1) var s S go func() { s.s1.x = 1 c <- true }() s.s1.y = 2 <-c } func TestRaceComp(t *testing.T) { c := make(chan bool, 1) var s S go func() { s.s2.y = 1 c <- true }() s.s2.y = 2 <-c } func TestRaceComp2(t *testing.T) { c := make(chan bool, 1) var s S go func() { s.s1.x = 1 c <- true }() s = S{}
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Sep 08 04:08:51 UTC 2014 - 2.3K bytes - Viewed (0) -
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) -
test/fixedbugs/bug222.dir/chanbug.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jan 24 19:48:15 UTC 2012 - 263 bytes - Viewed (0) -
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) -
src/cmd/go/internal/par/queue_test.go
) q := NewQueue(maxActive) t.Logf("q = NewQueue(%d)", maxActive) var wg sync.WaitGroup wg.Add(totalWork) started := make([]chan struct{}, totalWork) unblock := make(chan struct{}) for i := range started { started[i] = make(chan struct{}) i := i q.Add(func() { close(started[i]) <-unblock wg.Done() }) } for i, c := range started { if i < maxActive {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Aug 24 21:08:46 UTC 2020 - 1.4K bytes - Viewed (0) -
test/typeswitch.go
case float64: assert(x == 7.4 && i == Float, "float64") case string: assert(x == "hello" && i == String, "string") case S: assert(x.a == 1234 && i == Struct, "struct") case chan int: assert(x == c && i == Chan, "chan") case []int: assert(x[3] == 3 && i == Array, "array") case map[string]int: assert(x != nil && i == Map, "map") case func(i int) interface{}: assert(x != nil && i == Func, "fun")
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Feb 24 00:48:19 UTC 2012 - 1.8K bytes - Viewed (0) -
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) -
src/runtime/race/testdata/mutex_test.go
var x int16 = 0 _ = x ch := make(chan bool, 2) go func() { x = 1 mu.Lock() defer mu.Unlock() ch <- true }() go func() { x = 2 mu.Lock() mu.Unlock() ch <- true }() <-ch <-ch } func TestRaceMutex2(t *testing.T) { var mu1 sync.Mutex var mu2 sync.Mutex var x int8 = 0 _ = x ch := make(chan bool, 2) go func() { mu1.Lock()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Feb 23 22:14:38 UTC 2021 - 2K bytes - Viewed (0) -
misc/cgo/gmp/fib.go
// license that can be found in the LICENSE file. //go:build ignore // Compute Fibonacci numbers with two goroutines // that pass integers back and forth. No actual // concurrency, just threads and synchronization // and foreign code on multiple pthreads. package main import ( big "." "runtime" ) func fibber(c chan *big.Int, out chan string, n int64) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Apr 10 22:32:35 UTC 2023 - 919 bytes - Viewed (0) -
src/internal/reflectlite/set_test.go
x any t any b bool }{ {new(chan int), new(<-chan int), true}, {new(<-chan int), new(chan int), false}, {new(*int), new(IntPtr), true}, {new(IntPtr), new(*int), true}, {new(IntPtr), new(IntPtr1), false}, {new(Ch), new(<-chan any), true}, // test runs implementsTests too } type IntPtr *int type IntPtr1 *int type Ch <-chan any func TestAssignableTo(t *testing.T) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Dec 13 18:45:54 UTC 2021 - 2.4K bytes - Viewed (0)