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
{{ message }}
Repository navigation
Honor new properties on ObsoleteAttribute for .NET 5 #8654
namespaceSystem{publicpartialclassObsoleteAttribute:Attribute{// Existing://// public ObsoleteAttribute();// public ObsoleteAttribute(string message);// public ObsoleteAttribute(string message, bool error);// public bool IsError { get; }// public string Message { get; }// New:publicstringDiagnosticId{get;set;}publicstringUrlFormat{get;set;}}}
That would make sense to me.
It was (safely) exposed as a new property of the compiler service returning structured data, but not used for normal diagnostic output.
Changing this will also mean it should no longer react to --nowarn:44 and instead to its own nowarn.
Activity
abelbraaksma commentedon Mar 4, 2020
abelbraaksma commentedon Mar 4, 2020
terrajobst commentedon Mar 4, 2020
jwosty commentedon Jul 25, 2026
Unless I'm misunderstanding something, the compiler doesn't seem to surface DiagnosticId as the error number.
For example, compiling this under .NET 10.0.302:
Gives this output:
Shouldn't that produce FS999 rather than FS0044? @T-Gro
T-Gro commentedon Aug 1, 2026
That would make sense to me.
It was (safely) exposed as a new property of the compiler service returning structured data, but not used for normal diagnostic output.
Changing this will also mean it should no longer react to --nowarn:44 and instead to its own nowarn.
jwosty commentedon Aug 1, 2026
To be fair, that is how it works in C# and how I assumed it was going to work when I tried it out. Just some end user data for you :)
I would love for there to be a way to
#nowarna particular custom warning