官方教程:Go fuzzing模糊测试 2022-02-27 go fuzzing 7513 words 15 mins read 前言 Go 1.18在go工具链里引入了fuzzing模糊测试,可以帮助我们发现Go代码里的漏洞或者可能导致程序崩溃的输入。Go官方团队也在官网发 Read more...
Go Quiz: 从Go面试题看函数命名返回值的注意事项 2022-02-20 go quiz closure 1954 words 4 mins read 题目 Redhat的首席工程师、Prometheus开源项目Maintainer Bartłomiej Płotka 在Twitter上出了一道Go Read more...
Go语言中fmt.Println(true)的结果一定是true么? 2022-02-16 go 865 words 2 mins read 背景 Honeycomb的首席开发布道者Jessica在Twitter上发了一条状态: fmt.Println(“What is truth?”, true) can output: What is truth? false 意思是下面代码的执行结果可能是Wha Read more...
Go Quiz: 从Go面试题看panic注意事项第1篇 2022-02-07 go quiz 面试题 835 words 2 mins read 面试题 这是Go Quiz系列里关于panic的第1篇,主要考察同一个goroutine在多次panic场景下recover的机制。 1 2 3 4 5 6 Read more...
Go 1.18将移除用于泛型的constraints包 2022-02-03 go generics 泛型 1798 words 4 mins read 背景 Go官方团队在Go 1.18 Beta 1版本的标准库里因为泛型设计而引入了contraints包。 constraints包里定义了Signed,Unsi Read more...