rust-clippy/tests/ui/modulo_one.rs

10 lines
153 B
Rust
Raw Normal View History

2018-07-28 15:34:52 +00:00
#![feature(tool_lints)]
2017-09-18 10:47:33 +00:00
2018-07-28 15:34:52 +00:00
#![warn(clippy::modulo_one)]
#![allow(clippy::no_effect, clippy::unnecessary_operation)]
fn main() {
2017-02-08 13:58:07 +00:00
10 % 1;
10 % 2;
}