Skip to content

Commit c564661

Browse files
committed
Update uitests
1 parent 27488fe commit c564661

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

tests/ui/xor_used_as_pow.stderr

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,3 +50,17 @@ LL | let _ = 10 ^ 0;
5050

5151
error: aborting due to 7 previous errors
5252

53+
error: it appears you are trying to get a power of two, but `^` is not an exponentiation operator
54+
--> $DIR/xor_used_as_pow.rs:29:17
55+
|
56+
LL | let _ = 2 ^ x;
57+
| ^^^^ help: use a bitshift instead: `1_u32 << 15`
58+
59+
error: `^` is not an exponentiation operator but appears to have been used as one
60+
--> $DIR/xor_used_as_pow.rs:30:17
61+
|
62+
LL | let _ = 10 ^ x;
63+
| ^^^^^
64+
|
65+
= help: did you mean to use .pow()?
66+

0 commit comments

Comments
 (0)