摘要:
单任务队列耗时 package main import ( "crypto/rand" "fmt" "math/big" "strconv" "strings" "sync" "time" ) type task struct { id uint32 // callback chan int } v
阅读全文
posted @ 2020-09-12 17:28
longzhankunlun
阅读(1135)
推荐(0)
编辑
摘要:
package main import "sync" var sm sync.Map var sm1 *sync.Map var m map[int]string func main() { sm.Store(1, "xixi") sm1.Store(1, "xixi") // 此处因为没有分配内存
阅读全文
posted @ 2020-09-12 10:01
longzhankunlun
阅读(472)
推荐(0)
编辑