From c2841e2a1eb2712d580ef83cb7986151ece8c516 Mon Sep 17 00:00:00 2001 From: clubby789 Date: Fri, 15 Sep 2023 15:54:47 +0000 Subject: Migrate 'cast to bool' diagnostic --- tests/ui/error-codes/E0054.stderr | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'tests/ui/error-codes') diff --git a/tests/ui/error-codes/E0054.stderr b/tests/ui/error-codes/E0054.stderr index ea81f4476a7..0a4adabbaf6 100644 --- a/tests/ui/error-codes/E0054.stderr +++ b/tests/ui/error-codes/E0054.stderr @@ -2,7 +2,12 @@ error[E0054]: cannot cast `i32` as `bool` --> $DIR/E0054.rs:3:24 | LL | let x_is_nonzero = x as bool; - | ^^^^^^^^^ help: compare with zero instead: `x != 0` + | ^^^^^^^^^ + | +help: compare with zero instead + | +LL | let x_is_nonzero = x != 0; + | ~~~~ error: aborting due to previous error -- cgit 1.4.1-3-g733a5