package main func test() error { return nil } func main() { err := test() if err != nil { return } }