Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
nikomatsakis
left a comment
There was a problem hiding this comment.
Left some notes on how to make this support lint groups (I think)
nikomatsakis
left a comment
There was a problem hiding this comment.
Can you add an entry to the unstable book compiler flags listing:
https://github.com/rust-lang/rust/tree/master/src/doc/unstable-book/src/compiler-flags
I'm not sure if there is a SUMMARY.md to edit
This comment has been minimized.
This comment has been minimized.
|
Can this feature be implemented more simply as an additional lint level, similar to "forbid" but for warnings? |
|
@cjgillot I think it would be possible, but I'm not convinced it would be more simple. We want these lints to behave as they currently do in all situations except in the one case where we want to force them to warn. Having another lint level would force more of a cognitive burden on users and documentation maintenance. |
This comment has been minimized.
This comment has been minimized.
|
@bors r+ |
|
📌 Commit 896898e has been approved by |
|
☀️ Test successful - checks-actions |
Make ForceWarn a lint level. Follow-up to rust-lang#85788 cc `@rylev`
Implements #85512.
This PR adds a new command line option
force-warnswhich will force the provided lints to warn even if they are allowed by some other mechanism such as#![allow(warnings)].Some remaining issues:
force-warnsshould also be capable of taking lint groups instead of individual lints. This is not implemented.warn, this will cause that lint to warn instead. We probably want to allow the lint to error if it is set to a higher lint and is not allowed somewhere else.force-warns. I'm not sure why, but I wanted to get this in before the weekend.r? @nikomatsakis