-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Labels
enhancementNew feature or requestNew feature or request
Description
The analyzer does not handle record classes.
for example :
[Closed(typeof(UserNotFound))]
public abstract record Response
{
public record UserNotFound : Response;
public record Success : Response;
}
class Controller
{
public int Get(Response response)
{
return response switch
{
Response.UserNotFound _ => -1,
_ => throw ExhaustiveMatch.Failed(response)
};
}
}The analyzer doesn't detect that the "Success" class is needed to be added to the Closed attribute.
The analyzer doesn't detect that the "Success" clause needs to be handled in the Get() method
Thanks for this library, really appreciate the effort !
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request