It doesn't deal with the fact that we used form do def foo()... in many places and those won't work with def+rescue. However, I don't think we should change that.
Instead, I think we should add a common check to all learning exercises that don't require any rescuing that warns students that using raising and rescuing errors for flow control is an antipattern and might result in other analyzer feedback being invalid.
This PR partially deals with https://github.com/exercism/elixir-analyzer/issues/350 by handling
def
anddefp
withrescue
blocks inassert_call
.It doesn't deal with the fact that we used
form do def foo()...
in many places and those won't work withdef+rescue
. However, I don't think we should change that.Instead, I think we should add a common check to all learning exercises that don't require any rescuing that warns students that using raising and rescuing errors for flow control is an antipattern and might result in other analyzer feedback being invalid.