You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently nargo treats warnings as errors by default. This is not only opposite to how other compilers (notably rustc and clang/gcc) handle warnings, but also leads to a few issues:
Deprecation warnings are errors by default, which causes more friction than intended when deprecating features.
Unused variables prevent compilation by default.
There is no indication that the above two errors were originally warnings that were treated as errors. Thus, unless users are very familiar with the compiler they are usually lead to stop and fix the issues rather than passing the --allow-warnings flag.
Happy Case
Noir & Nargo should instead switch to enabling warnings by default and only treating them as errors when a new --deny-warnings flag is passed. The old --allow-warnings flag should be removed.
The name --deny-warnings was chosen to match the name of the same flag in rustc.
Alternatives Considered
No response
Additional Context
No response
Would you like to submit a PR for this Issue?
Yes
Support Needs
No response
The text was updated successfully, but these errors were encountered:
Problem
Currently nargo treats warnings as errors by default. This is not only opposite to how other compilers (notably rustc and clang/gcc) handle warnings, but also leads to a few issues:
--allow-warnings
flag.Happy Case
Noir & Nargo should instead switch to enabling warnings by default and only treating them as errors when a new
--deny-warnings
flag is passed. The old--allow-warnings
flag should be removed.The name
--deny-warnings
was chosen to match the name of the same flag in rustc.Alternatives Considered
No response
Additional Context
No response
Would you like to submit a PR for this Issue?
Yes
Support Needs
No response
The text was updated successfully, but these errors were encountered: