We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Similar to #97737, we should support more scenarios where we know a Type is an Enum type without emitting warnings.
The example scenario comes from https://github.com/microsoft/OpenAPI.NET/pull/1717/files#diff-c59c9153ccf5e00142826d1c5e4d3d92470aac0bc740a302a23557432141277c
public static T GetAttributeOfType<T>(this Enum enumValue) where T : Attribute { var type = enumValue.GetType(); var memInfo = type.GetField(enumValue.ToString(), BindingFlags.Public | BindingFlags.Static);
This code shouldn't warn because type is guaranteed to be an Enum type.
type
This scenario was explicitly not supported in #105351. We should support it.
cc @sbomer @MichalStrehovsky
The text was updated successfully, but these errors were encountered:
Tagging subscribers to this area: @agocke, @MichalStrehovsky, @jkotas See info in area-owners.md if you want to be subscribed.
Sorry, something went wrong.
Tagging subscribers to this area: @agocke, @sbomer, @vitek-karas See info in area-owners.md if you want to be subscribed.
7102706
sbomer
Successfully merging a pull request may close this issue.
Similar to #97737, we should support more scenarios where we know a Type is an Enum type without emitting warnings.
The example scenario comes from https://github.com/microsoft/OpenAPI.NET/pull/1717/files#diff-c59c9153ccf5e00142826d1c5e4d3d92470aac0bc740a302a23557432141277c
This code shouldn't warn because
type
is guaranteed to be an Enum type.This scenario was explicitly not supported in #105351. We should support it.
cc @sbomer @MichalStrehovsky
The text was updated successfully, but these errors were encountered: