collapsible_match suggestion changes behaviour #6740
Labels
C-bug
Category: Clippy is not doing the correct thing
good-first-issue
These issues are a good way to get started with Clippy
I-false-positive
Issue: The lint was triggered on code it shouldn't have
Lint name: collapsible_match
Clippy suggests collapsing the nested match in the following code snippet (the full code is here):
I expected to see this happen: no Clippy warning
Instead, this happened:
This suggestion is invalid. It changes the type of the error object is returned and noticeably changes the behaviour of the code (in this case the error message printed to the command-line changes).
Meta
cargo clippy -V
: clippy 0.0.212 (cb75ad5 2021-02-10)rustc -Vv
:The text was updated successfully, but these errors were encountered: