Skip to content

Commit 90eee7d

Browse files
committed
Remove early error abort
1 parent 0195714 commit 90eee7d

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

src/librustc_driver/driver.rs

-1
Original file line numberDiff line numberDiff line change
@@ -1211,7 +1211,6 @@ where
12111211
.set(derive_registrar::find(&hir_map));
12121212

12131213
time(sess, "loop checking", || loops::check_crate(sess, &hir_map));
1214-
sess.abort_if_errors();
12151214

12161215
let mut local_providers = ty::query::Providers::default();
12171216
default_provide(&mut local_providers);

src/test/ui/issue-51714.rs

+1
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,5 @@ fn main() {
2020

2121
[(); return while let Some(n) = Some(0) {}];
2222
//~^ ERROR return statement outside of function body
23+
//~^^ ERROR irrefutable while-let pattern
2324
}

src/test/ui/issue-51714.stderr

+9-2
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,13 @@ error[E0572]: return statement outside of function body
2222
LL | [(); return while let Some(n) = Some(0) {}];
2323
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2424

25-
error: aborting due to 4 previous errors
25+
error[E0165]: irrefutable while-let pattern
26+
--> $DIR/issue-51714.rs:21:27
27+
|
28+
LL | [(); return while let Some(n) = Some(0) {}];
29+
| ^^^^^^^ irrefutable pattern
30+
31+
error: aborting due to 5 previous errors
2632

27-
For more information about this error, try `rustc --explain E0572`.
33+
Some errors occurred: E0165, E0572.
34+
For more information about an error, try `rustc --explain E0165`.

0 commit comments

Comments
 (0)