roslynator
roslynator copied to clipboard
Feature request: detect and suggest discards in tuple deconstruction
trafficstars
Code along these lines:
var (foo, bar, quux) = MethodThatReturnsATwoTuple();
foo.DoSomething();
// bar is never used and could be discarded
quux.AnotherThing();
could be rewritten as:
var (foo, _, quux) = MethodThatReturnsATwoTuple();
foo.DoSomething();
quux.AnotherThing();