-
Notifications
You must be signed in to change notification settings - Fork 10.6k
[Diagnostics] Replace diagnostics' DefaultIgnore option with a corresponding option on diagnostic groups
#85098
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
Conversation
e44c07f to
5395e8b
Compare
|
@swift-ci test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love this, thank you!
5395e8b to
83eea39
Compare
|
@swift-ci smoke test |
51c5d05 to
9e9d91b
Compare
|
@swift-ci smoke test |
9e9d91b to
79e3542
Compare
|
@swift-ci smoke test |
|
|
||
| /// The diagnostic warnings belonging to this group should be ignored by default, | ||
| /// but will be re-enabled by various warning options (-Wwarning, -Werror). | ||
| DefaultIgnoreWarnings, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
out of curiosity, is functionality like this expected to remain 'one way'? i.e. you can go from ignored to not, but you can't go back.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's right; but, we're building towards a way to go in the other direction with source-level controls:
https://forums.swift.org/t/pitch-source-level-control-over-compiler-warnings/
79e3542 to
f2ac958
Compare
|
@swift-ci smoke test |
…esponding option on diagnostic groups This brings this control in line with other diagnostic controls we have which operate on a per-group level. 'DefaultIgnoreWarnings' diagnostic group option applies to all warnings belonging to a certain diagnostic group. The inheritance rules are: - Marking a diagnostic group as 'DefaultIgnoreWarnings' means warnings belonging to this group will not be emitted by-default - Warnings belonging to sub-groups of this group will also not be emitted by-default - Enabling a 'DefaultIgnoreWarnings' group (with '-Werror','-Wwarning', etc.) means warnings belonging to this group will be emitted. - Warnings belonging to sub-groups of this group will also be emitted. - Warnings belonging to super-groups of this group will not be affected.
f2ac958 to
9e35f82
Compare
|
@swift-ci smoke test |
This brings this control in line with other diagnostic controls we have which operate on a per-group level.
DefaultIgnoreWarningsdiagnostic group option applies to all warnings belonging to a certain diagnostic group.The inheritance rules are:
DefaultIgnoreWarningsmeans warnings belonging to this group will not be emitted by-defaultDefaultIgnoreWarningsgroup (with-Werror,-Wwarning, etc.) means warnings belonging to this group will be emitted.