- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for utime (0.15 sec)
-
doc/go1.22.html
requires deferring the <code>time.Since</code> call. For example: </p> <pre> t := time.Now() defer log.Println(time.Since(t)) // non-deferred call to time.Since tmp := time.Since(t); defer log.Println(tmp) // equivalent to the previous defer defer func() { log.Println(time.Since(t)) // a correctly deferred call to time.Since }() </pre>
HTML - Registered: Tue Feb 06 11:13:10 GMT 2024 - Last Modified: Wed Jan 31 20:51:56 GMT 2024 - 45.6K bytes - Viewed (0) -
doc/go_mem.html
</p> <p> This program starts a goroutine for every entry in the work list, but the goroutines coordinate using the <code>limit</code> channel to ensure that at most three are running work functions at a time. </p> <pre> var limit = make(chan int, 3) func main() { for _, w := range work { go func(w func()) { limit <- 1 w() <-limit }(w) } select{} }
HTML - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Mon Mar 04 15:54:42 GMT 2024 - 26.6K bytes - Viewed (0)