0
点赞
收藏
分享

微信扫一扫

go-基础-错误终止-panic

ITWYY 2022-01-07 阅读 37
package main

import (
	"os"
)

func main() {
	panic("file not found")
	_, err := os.Create("tmp/file")
	if err != nil {
		panic(err)
	}
}

举报

相关推荐

0 条评论