- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 875 for channel2 (0.14 sec)
-
src/go/types/under.go
// If x and y are identical, match returns x. // If x and y are identical channels but for their direction // and one of them is unrestricted, match returns the channel // with the restricted direction. // In all other cases, match returns nil. func match(x, y Type) Type { // Common case: we don't have channels. if Identical(x, y) { return x } // We may have channels that differ in direction only. if x, _ := x.(*Chan); x != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue May 21 22:34:27 UTC 2024 - 2.8K bytes - Viewed (0) -
pkg/kubelet/config/mux.go
merger: merger, } return mux } // ChannelWithContext returns a channel where a configuration source // can send updates of new configurations. Multiple calls with the same // source will return the same channel. This allows change and state based sources // to use the same channel. Different source names however will be treated as a // union.
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jan 30 20:02:23 UTC 2024 - 2.3K bytes - Viewed (0) -
doc/next/6-stdlib/1-time.md
<!-- go.dev/issue/37196 --> Second, the timer channel associated with a `Timer` or `Ticker` is now unbuffered, with capacity 0. The main effect of this change is that Go now guarantees that for any call to a `Reset` or `Stop` method, no stale values prepared before that call will be sent or received after the call. Earlier versions of Go used channels with a one-element buffer,
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 20:49:22 UTC 2024 - 1.5K bytes - Viewed (0) -
src/main/java/org/codelibs/core/nio/ChannelUtil.java
import java.io.IOException; import java.nio.ByteBuffer; import java.nio.channels.Channel; import java.nio.channels.FileChannel; import java.nio.channels.FileChannel.MapMode; import org.codelibs.core.exception.IORuntimeException; /** * {@link Channel}用のユーティリティです。 * * @author koichik */ public abstract class ChannelUtil { /**
Registered: Wed Jun 12 12:50:12 UTC 2024 - Last Modified: Thu Mar 07 01:59:08 UTC 2024 - 6K bytes - Viewed (0) -
test/typeparam/chansimp.dir/a.go
} // ReadAll reads from c until the channel is closed or the context is // canceled, returning all the values read. func ReadAll[Elem any](ctx context.Context, c <-chan Elem) []Elem { var r []Elem for { select { case <-ctx.Done(): return r case v, ok := <-c: if !ok { return r } r = append(r, v) } } } // Merge merges two channels into a single channel.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jul 28 21:40:40 UTC 2021 - 5.5K bytes - Viewed (0) -
src/time/sleep.go
// a problem fixed by asynctimerchan=1: it enables the new // GC-able timer channels (#61542) but not the sync channels (#37196). // // If we decide to roll back the sync channels, we will still have // a fully tested async runtime implementation (asynctimerchan=2) // and can make this function always return c. // // If we decide to keep the sync channels, we can delete all the // handling of asynctimerchan in the runtime and keep just this
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Apr 04 14:21:30 UTC 2024 - 8.5K bytes - Viewed (0) -
test/chan/perm.go
cr = cs // ERROR "illegal types|incompatible|cannot" cs = cr // ERROR "illegal types|incompatible|cannot" var n int <-n // ERROR "receive from non-chan|expected channel" n <- 2 // ERROR "send to non-chan|must be channel" c <- 0 // ok <-c // ok x, ok := <-c // ok _, _ = x, ok cr <- 0 // ERROR "send" <-cr // ok x, ok = <-cr // ok _, _ = x, ok
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Jul 14 23:33:46 UTC 2021 - 1.4K bytes - Viewed (0) -
test/chan/select6.go
// Test for select: Issue 2075 // A bug in select corrupts channel queues of failed cases // if there are multiple waiters on those channels and the // select is the last in the queue. If further waits are made // on the channel without draining it first then those waiters // will never wake up. In the code below c1 is such a channel. package main func main() { c1 := make(chan bool) c2 := make(chan bool)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 02 13:43:18 UTC 2016 - 783 bytes - Viewed (0) -
test/chan/sieve1.go
// Generate primes up to 100 using channels, checking the results. // This sieve consists of a linear chain of divisibility filters, // equivalent to trial-dividing each n by all primes p ≤ n. package main // Send the sequence 2, 3, 4, ... to channel 'ch'. func Generate(ch chan<- int) { for i := 2; ; i++ { ch <- i // Send 'i' to channel 'ch'. } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Sun Feb 19 06:44:02 UTC 2012 - 1.5K bytes - Viewed (0) -
test/typeparam/chans.go
} // _ReadAll reads from c until the channel is closed or the context is // canceled, returning all the values read. func _ReadAll[Elem any](ctx context.Context, c <-chan Elem) []Elem { var r []Elem for { select { case <-ctx.Done(): return r case v, ok := <-c: if !ok { return r } r = append(r, v) } } } // _Merge merges two channels into a single channel.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 19:45:34 UTC 2022 - 8.4K bytes - Viewed (0)