Silence CS8632 nullable annotation spam project-wide - #267
Merged
Conversation
A clean build produces 1565 warnings, 2796 of the raw lines CS8632
("nullable annotation used outside a #nullable context"), all from
vanilla files the decompiler emits with the original assembly's own
nullable annotations intact. None of them come from Stratum's own
patches: contributors already avoid adding new nullable annotations
to files without #nullable enable, per the style rules. A real
compile error sitting among that many warnings is easy to miss, which
is exactly what #263 reports and screenshots.
Adds CS8632 to Directory.Build.props's existing NoWarn list, the same
mechanism already silencing eight other decompiler-inherent codes
(CS1591, CS1572, CS1573, CS1570, CS0649, CS0414, CS0169, CS0162,
CS0168). NoWarn only affects warnings; a real compile error still
stops the build and prints regardless of this list.
Verified with a clean rebuild before and after: 1565 warnings down to
167, zero CS8632 remaining, 0 errors both times. Smoke test passes,
server reaches RunGame with no fatal errors.
Fixes #263
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A clean build of
VintageStory.slnxproduces 1565 warnings, and 2796 of the raw warning lines are CS8632 ("nullable annotation used outside a #nullable context"). All of it comes from vanilla files the decompiler emits with the original assembly's own nullable annotations intact, not from Stratum's own patches. A real compile error sitting among that many warnings is easy to miss, which is exactly what #263 reports and screenshots: a genuineCS1503buried in a wall ofCS8632.Fix: add
CS8632toDirectory.Build.props's existingNoWarnlist, the same mechanism already silencing eight other decompiler-inherent codes (CS1591,CS1572,CS1573,CS1570,CS0649,CS0414,CS0169,CS0162,CS0168).NoWarnonly affects warnings; a real compile error still stops the build and prints regardless of this list, so nothing about error visibility changes, only the noise around it.Type
Checklist
.\scripts\extract-patches.ps1ran clean. Not applicable: no vanilla file touched, only the sharedDirectory.Build.propsMSBuild config, so there's nothing for extract-patches to regenerate.dotnet build VintageStory.slnx -c Releaseis green.// Stratummarker. Not applicable, same reason: no vanilla file edited.Performance numbers
Not a performance change, but the fix is a number, so here it is anyway. Clean rebuild (
--no-incremental) before and after, same tree:Smoke test passes both before and after: server reaches
RunGame, no fatal errors.Related issues
Fixes #263