josefs / Gradualizer

A Gradual type system for Erlang
MIT License
613 stars 35 forks source link

Improve unsupported expression (e.g. maybe) handling #494

Open erszcz opened 1 year ago

erszcz commented 1 year ago

I was just thinking about a few more things.

We handle maybe (unsupported expression clause) in do_type_check_expr. Shouldn't we also have such clause in do_type_check_expr_in? I believer we can trigger this by adding the same maybe-test again but with a spec.

Should we enable the maybe expression in the escript too? We generate the emulator options line in the Makefile like %%! -escript main gradualizer_cli.

Originally posted by @zuiderkwast in https://github.com/josefs/Gradualizer/pull/489#pullrequestreview-1203463723

See also https://github.com/josefs/Gradualizer/pull/489#discussion_r1038776136

zuiderkwast commented 1 year ago

Thanks for opening the issue.