]> git.lizzy.rs Git - rust.git/blob - src/test/ui/type/type-check/assignment-expected-bool.stderr
Remove E0308 note when primary label has all info
[rust.git] / src / test / ui / type / type-check / assignment-expected-bool.stderr
1 error[E0308]: mismatched types
2   --> $DIR/assignment-expected-bool.rs:6:19
3    |
4 LL |     let _: bool = 0 = 0;
5    |                   ^^^^^
6    |                   |
7    |                   expected bool, found ()
8    |                   help: try comparing for equality: `0 == 0`
9
10 error[E0308]: mismatched types
11   --> $DIR/assignment-expected-bool.rs:9:14
12    |
13 LL |         0 => 0 = 0,
14    |              ^^^^^
15    |              |
16    |              expected bool, found ()
17    |              help: try comparing for equality: `0 == 0`
18
19 error[E0308]: mismatched types
20   --> $DIR/assignment-expected-bool.rs:10:14
21    |
22 LL |         _ => 0 = 0,
23    |              ^^^^^
24    |              |
25    |              expected bool, found ()
26    |              help: try comparing for equality: `0 == 0`
27
28 error[E0308]: mismatched types
29   --> $DIR/assignment-expected-bool.rs:14:17
30    |
31 LL |         true => 0 = 0,
32    |                 ^^^^^
33    |                 |
34    |                 expected bool, found ()
35    |                 help: try comparing for equality: `0 == 0`
36
37 error[E0308]: mismatched types
38   --> $DIR/assignment-expected-bool.rs:18:8
39    |
40 LL |     if 0 = 0 {}
41    |        ^^^^^
42    |        |
43    |        expected bool, found ()
44    |        help: try comparing for equality: `0 == 0`
45
46 error[E0308]: mismatched types
47   --> $DIR/assignment-expected-bool.rs:20:24
48    |
49 LL |     let _: bool = if { 0 = 0 } {
50    |                        ^^^^^
51    |                        |
52    |                        expected bool, found ()
53    |                        help: try comparing for equality: `0 == 0`
54
55 error[E0308]: mismatched types
56   --> $DIR/assignment-expected-bool.rs:21:9
57    |
58 LL |         0 = 0
59    |         ^^^^^
60    |         |
61    |         expected bool, found ()
62    |         help: try comparing for equality: `0 == 0`
63
64 error[E0308]: mismatched types
65   --> $DIR/assignment-expected-bool.rs:23:9
66    |
67 LL |         0 = 0
68    |         ^^^^^
69    |         |
70    |         expected bool, found ()
71    |         help: try comparing for equality: `0 == 0`
72
73 error[E0308]: mismatched types
74   --> $DIR/assignment-expected-bool.rs:26:13
75    |
76 LL |     let _ = (0 = 0)
77    |             ^^^^^^^
78    |             |
79    |             expected bool, found ()
80    |             help: try comparing for equality: `0 == 0`
81
82 error[E0308]: mismatched types
83   --> $DIR/assignment-expected-bool.rs:27:14
84    |
85 LL |         && { 0 = 0 }
86    |              ^^^^^
87    |              |
88    |              expected bool, found ()
89    |              help: try comparing for equality: `0 == 0`
90
91 error[E0308]: mismatched types
92   --> $DIR/assignment-expected-bool.rs:28:12
93    |
94 LL |         || (0 = 0);
95    |            ^^^^^^^
96    |            |
97    |            expected bool, found ()
98    |            help: try comparing for equality: `0 == 0`
99
100 error[E0070]: invalid left-hand side expression
101   --> $DIR/assignment-expected-bool.rs:31:20
102    |
103 LL |     let _: usize = 0 = 0;
104    |                    ^^^^^ left-hand of expression not valid
105
106 error[E0308]: mismatched types
107   --> $DIR/assignment-expected-bool.rs:31:20
108    |
109 LL |     let _: usize = 0 = 0;
110    |                    ^^^^^ expected usize, found ()
111
112 error: aborting due to 13 previous errors
113
114 Some errors have detailed explanations: E0070, E0308.
115 For more information about an error, try `rustc --explain E0070`.