I have two questions about programming style and errors in Julia:
- Is it considered good style to have functions validate their inputs, and throw informative errors if an input’s value would cause an error?
- What type of error should be thrown in that case? I have been using
ArgumentErrorbut when I look at the documentation, it seems like
ArgumentErrormay have been intended for situations where no method matching the type signature at the call site was found.