import sys struct Struct { func *any } main() { s := new(Struct) s.func = f s.func() sys.exit(1) } f() { sys.exit(0) }