Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

@code_warntype with no arguments throws cryptic error #40073

Open
jlumpe opened this issue Mar 17, 2021 · 0 comments
Open

@code_warntype with no arguments throws cryptic error #40073

jlumpe opened this issue Mar 17, 2021 · 0 comments
Labels
domain:error messages Better, more actionable error messages

Comments

@jlumpe
Copy link
Contributor

jlumpe commented Mar 17, 2021

julia> @code_warntype
ERROR: LoadError: BoundsError: attempt to access ()
  at index [0]

Seems to be trying to get the first expression out of an empty tuple. Suggest should throw the same error as when called with multiple arguments:

julia> @code_warntype foo bar
ERROR: @code_warntype expects only one non-keyword argument

This applies to @code_llvm and @code_native as well.

@brenhinkeller brenhinkeller added the domain:error messages Better, more actionable error messages label Nov 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:error messages Better, more actionable error messages
Projects
None yet
Development

No branches or pull requests

2 participants