Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 1,296 for chan2 (0.04 sec)

  1. internal/grid/muxserver.go

    		if debugPrint {
    			fmt.Println("connected stream mux:", ack.MuxID)
    		}
    	}()
    
    	// Data inbound to the handler
    	var handlerIn chan []byte
    	if inboundCap > 0 {
    		m.inbound = make(chan []byte, inboundCap)
    		handlerIn = make(chan []byte, 1)
    		go func(inbound chan []byte) {
    			wg.Wait()
    			defer xioutil.SafeClose(handlerIn)
    			m.handleInbound(c, inbound, handlerIn)
    		}(m.inbound)
    	}
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Fri Jun 07 15:51:52 UTC 2024
    - 9.7K bytes
    - Viewed (0)
  2. 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)
  3. src/internal/trace/testdata/testprog/stacks.go

    	go func() { // func1
    		select {}
    	}()
    	go func() { // func2
    		var c chan int
    		c <- 0
    	}()
    	go func() { // func3
    		var c chan int
    		<-c
    	}()
    	done1 := make(chan bool)
    	go func() { // func4
    		<-done1
    	}()
    	done2 := make(chan bool)
    	go func() { // func5
    		done2 <- true
    	}()
    	c1 := make(chan int)
    	c2 := make(chan int)
    	go func() { // func6
    		select {
    		case <-c1:
    		case <-c2:
    		}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 18:48:18 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  4. src/runtime/race/output_test.go

    	{"midstack_inlining_traceback", "run", "linux", "atexit_sleep_ms=0", `
    package main
    
    var x int
    var c chan int
    func main() {
    	c = make(chan int)
    	go f()
    	x = 1
    	<-c
    }
    
    func f() {
    	g(c)
    }
    
    func g(c chan int) {
    	h(c)
    }
    
    func h(c chan int) {
    	c <- x
    }
    `, []string{`==================
    WARNING: DATA RACE
    Read at 0x[0-9,a-f]+ by goroutine [0-9]:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Oct 25 20:44:25 UTC 2023
    - 9.3K bytes
    - Viewed (0)
  5. src/runtime/proc_test.go

    			// iteration is 2 * (runtime overhead + chan
    			// send/receive pair + delay + wakeDelay). This allows
    			// the runtime overhead, including the time it takes
    			// for the unblocked goroutine to be scheduled, to be
    			// estimated.
    			ping, pong := make(chan struct{}), make(chan struct{})
    			start := make(chan struct{})
    			done := make(chan struct{})
    			go func() {
    				<-start
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jun 14 00:03:57 UTC 2023
    - 25.8K bytes
    - Viewed (0)
  6. src/internal/types/testdata/check/expr2.go

    	_ = p1 == ps1
    }
    
    func channels() {
    	// basics
    	var c, d chan int
    	_ = c == d
    	_ = c != d
    	_ = c == nil
    	_ = c /* ERROR "< not defined" */ < d
    
    	// various element types (named types)
    	type (
    		C1 chan int
    		C1r <-chan int
    		C1s chan<- int
    		C2 chan float32
    	)
    	var (
    		c1 C1
    		c1r C1r
    		c1s C1s
    		c1a chan int
    		c2 C2
    	)
    	_ = c1 == c1
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:54:27 UTC 2023
    - 5K bytes
    - Viewed (0)
  7. src/sync/rwmutex_test.go

    func parallelReader(m *RWMutex, clocked, cunlock, cdone chan bool) {
    	m.RLock()
    	clocked <- true
    	<-cunlock
    	m.RUnlock()
    	cdone <- true
    }
    
    func doTestParallelReaders(numReaders, gomaxprocs int) {
    	runtime.GOMAXPROCS(gomaxprocs)
    	var m RWMutex
    	clocked := make(chan bool)
    	cunlock := make(chan bool)
    	cdone := make(chan bool)
    	for i := 0; i < numReaders; i++ {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Oct 29 17:13:13 UTC 2021
    - 4.9K bytes
    - Viewed (0)
  8. src/cmd/compile/internal/types2/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)
  9. src/net/http/triv.go

    	for _, s := range os.Args {
    		fmt.Fprint(w, s, " ")
    	}
    }
    
    // a channel (just for the fun of it)
    type Chan chan int
    
    func ChanCreate() Chan {
    	c := make(Chan)
    	go func(c Chan) {
    		for x := 0; ; x++ {
    			c <- x
    		}
    	}(c)
    	return c
    }
    
    func (ch Chan) ServeHTTP(w http.ResponseWriter, req *http.Request) {
    	io.WriteString(w, fmt.Sprintf("channel send #%d\n", <-ch))
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 10 03:29:50 UTC 2024
    - 3.2K bytes
    - Viewed (0)
  10. src/go/parser/short_test.go

    	`package p; import "fmt"; func f() { fmt.Println("Hello, World!") };`,
    	`package p; func f() { if f(T{}) {} };`,
    	`package p; func f() { _ = <-chan int(nil) };`,
    	`package p; func f() { _ = (<-chan int)(nil) };`,
    	`package p; func f() { _ = (<-chan <-chan int)(nil) };`,
    	`package p; func f() { _ = <-chan <-chan <-chan <-chan <-int(nil) };`,
    	`package p; func f(func() func() func());`,
    	`package p; func f(...T);`,
    	`package p; func f(float, ...int);`,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 02 12:56:53 UTC 2023
    - 10.1K bytes
    - Viewed (0)
Back to top