packagemain import( "fmt" "os" ) funcmain(){ //退出当前程序 deferfmt.Println("Doingsomething...") fmt.Println("Ohno,fatalerror!") os.Exit(1) }
packagemain import( "fmt" "os" ) funcmain(){ //退出当前程序 deferfmt.Println("Doingsomething...") fmt.Println("Ohno,fatalerror!") os.Exit(1) }