error: denote infinite loops with `loop { ... }` --> $DIR/lint-impl-fn.rs:10:21 | LL | fn bar(&self) { while true {} } //~ ERROR: infinite loops | ^^^^^^^^^^ help: use `loop` | note: lint level defined here --> $DIR/lint-impl-fn.rs:9:12 | LL | #[deny(while_true)] | ^^^^^^^^^^ error: denote infinite loops with `loop { ... }` --> $DIR/lint-impl-fn.rs:18:25 | LL | fn foo(&self) { while true {} } //~ ERROR: infinite loops | ^^^^^^^^^^ help: use `loop` | note: lint level defined here --> $DIR/lint-impl-fn.rs:13:8 | LL | #[deny(while_true)] | ^^^^^^^^^^ error: denote infinite loops with `loop { ... }` --> $DIR/lint-impl-fn.rs:27:5 | LL | while true {} //~ ERROR: infinite loops | ^^^^^^^^^^ help: use `loop` | note: lint level defined here --> $DIR/lint-impl-fn.rs:25:8 | LL | #[deny(while_true)] | ^^^^^^^^^^ error: aborting due to 3 previous errors