-
Notifications
You must be signed in to change notification settings - Fork 4k
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
IDE0060 (unused param) with NotImplementedException #56317
Comments
@LWChris can you supply a repro project? Pointing to a git repo at a particular commit would be helpful. |
@CyrusNajmabadi Sure, but this is literally just an empty project with one method in it: https://github.com/LWChris/IDE0060_NET5/tree/762dd94f3a02ae25120a8a956b621fd01432eb51 I found that the error toggles in and out of existence. Sometimes, the error disappears, but cutting and pasting the method makes it re-appear. Sometimes it disappears if you change something unrelated (e. g. add, rename or delete a completely unrelated class), or if you add a second method, that one does not have the message. Seems like the surpression doesn't work reliably. VS is 16.11.3 now. |
Tagging @mavasani |
Based on the last comment, it seems likely to be an issue with the solution crawler or error list, rather then the analyzer itself. I'll take a look. |
Fixes dotnet#56317 dotnet#42408 handled bailing out reporting unused params for methods that only have a throw operation in its body. It missed a case where the throw might be wrapped within a conversion wrapped within a return operation, which happens when the method returns a non-void type.
This has been requested earlier as #41236.
I'm not sure but it looks like
I have 16.11.2, but still see this issue.
So either this is broken again, it never worked, or there's a side-case where the fix doesn't work.
My project has
net5.0-windows10.0.17763
as target framework.The text was updated successfully, but these errors were encountered: