_demo: setjmp
This commit is contained in:
@@ -2,7 +2,6 @@ package main
|
||||
|
||||
import (
|
||||
"github.com/goplus/llgo/c/setjmp"
|
||||
"github.com/goplus/llgo/c/setjmp/trycatch"
|
||||
)
|
||||
|
||||
func main() {
|
||||
@@ -10,7 +9,6 @@ func main() {
|
||||
switch ret := setjmp.Sigsetjmp(&jb, 0); ret {
|
||||
case 0:
|
||||
println("Hello, setjmp!")
|
||||
trycatch.ThrowCppException()
|
||||
setjmp.Siglongjmp(&jb, 1)
|
||||
default:
|
||||
println("exception:", ret)
|
||||
|
||||
Reference in New Issue
Block a user