clojerl / clojerl

Clojure for the Erlang VM (unofficial)

Home Page:http://try.clojerl.online/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

throw in try expression returns :badarg in the REPL instead of generating exception

jfacorro opened this issue · comments

Describe the bug
When evaluating the expression (try (erlang/error :foo)) in the REPL instead of getting an error generated it returns :badarg.

To Reproduce

clje.user=> (try (erlang/error :foo))
:badarg

Expected behavior

clje.user=> (try (erlang/error :foo))
foo
clje.user=> (pst)
sadasa
        core_eval/expr_ (/Users/juan.facorro/dev/clojerl/clojerl/src/erl/core_eval.erl:98)
        core_eval/expr_ (/Users/juan.facorro/dev/clojerl/clojerl/src/erl/core_eval.erl:174)
        clj_compiler/eval1 (/Users/juan.facorro/dev/clojerl/clojerl/src/erl/clj_compiler.erl:144)

Actual behavior

clje.user=> (try (erlang/error "sadasa"))
:badarg
clje.user=> (pst)
nil

Context

  • clojerl version (tag/sha): 0.7.1-56-g0fcf2de