Expression value is never used IDE0058

Hi I configured this for C#.

I expected that rider will show an error but nothing happen.



Any suggestions?

2 comments
Comment actions Permalink

Hello Michael,

Thank you for contacting Rider support.

Rider should suggest removing the redundant initializer when the value you assign is not used until the next assignment is made in any of the execution paths. You can find the full inspection description here.

I am not sure about your code. Would you mind sharing a repro project with us? You can upload a project to the [Upload Service](https://uploads.jetbrains.com/) and let me know the Upload ID.

Thank you in advance and have a nice day!

0
Comment actions Permalink

I miss the warning that the _ = is missing in row 124 of the source code.

I see this warning in the VS 2022 IDE and also want to see it in my Rider IDE.

VS:

.

Rider:

0

Please sign in to leave a comment.