integer_arithmetic gives unhelpful warnings for const expressions #1761
Labels
C-bug
Category: Clippy is not doing the correct thing
E-medium
Call for participation: Medium difficulty level problem and requires some initial experience.
I-false-positive
Issue: The lint was triggered on code it shouldn't have
T-middle
Type: Probably requires verifiying types
I use the
integer_arithmetic
lint as a reminder to explicitly decide on what kind of behaviour I want, but it also triggers in situations like this line, where the math makes the line more readable and the*_mul
methods aren't available.It should probably be limited to non-constant expressions (or split into two lints) until an alternative is stabilized.
The text was updated successfully, but these errors were encountered: