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

refactor(AztecMacro): Improve warnings #3119

Open
Tracked by #5077
rahul-kothari opened this issue Oct 30, 2023 · 1 comment
Open
Tracked by #5077

refactor(AztecMacro): Improve warnings #3119

rahul-kothari opened this issue Oct 30, 2023 · 1 comment
Labels
C-aztec.nr Component: Aztec smart contract framework T-feedback Type: recording user feedback

Comments

@rahul-kothari
Copy link
Contributor

rahul-kothari commented Oct 30, 2023

  • "unused variable storage"
  • Say you have a function with 3 parameters. You pass two. Compiler error is "Passing 3 variables when required 4". This is confusing because end user doesn't know we manually add context under the hood. instead show the whole function signature.
@rahul-kothari rahul-kothari added C-aztec.nr Component: Aztec smart contract framework T-feedback Type: recording user feedback labels Oct 30, 2023
@spalladino
Copy link
Collaborator

Also reported by @drgorillamd from Wonderland

small compiler bug: as storageis now implicitly declared in every fn, is a fn doesn't use it (compute_note_hash_and_nullifier being a classic example I guess), one get a warning "unused variable storage" + bonus: the warning always point to line 1 of main.nr (even if it's a comment, like here)

@LHerskind LHerskind changed the title Better macro warnings refactor(AztecMacro): Improve warnings Mar 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-aztec.nr Component: Aztec smart contract framework T-feedback Type: recording user feedback
Projects
Status: Todo
Development

No branches or pull requests

2 participants