Closed hlship closed 2 years ago
Note that:
user=> (require '[joker.strconv :refer [atoi]])
nil
user=> (atoi "3.2")
<repl>:7:1: Eval error: strconv.Atoi: parsing "3.2": invalid syntax
user=> (try (atoi "3.2") (catch Error e (prn (ex-message e))))
"strconv.Atoi: parsing \"3.2\": invalid syntax"
nil
I'll work on a PR for this.
Calls to the parse-fn option are supposed to be wrapped such that exceptions are promotted into parse errors; that either isn't happening, or the strack trace of the thrown exception is becoming the error message.