robertkrimen / otto

A JavaScript interpreter in Go (golang)
http://godoc.org/github.com/robertkrimen/otto
MIT License
8.11k stars 586 forks source link

can't handle panic from native func with try catch block #383

Closed ilyapashuk closed 1 year ago

ilyapashuk commented 4 years ago

Code: try { panicingfunc() } catch (err) { "panic triggered" } expected: catch panic and return "panic triggered"

real behavior: panic is not recovered and passed to the caller