Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
eholk committed Mar 7, 2022
1 parent 1afbf3e commit bb6bcaa
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/test/ui/consts/unstable-const-fn-in-libcore.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0015]: cannot call non-const closure in constant functions
--> $DIR/unstable-const-fn-in-libcore.rs:23:26
--> $DIR/unstable-const-fn-in-libcore.rs:22:26
|
LL | Opt::None => f(),
| ^^^
Expand All @@ -11,7 +11,7 @@ LL | const fn unwrap_or_else<F: FnOnce() -> T + ~const std::ops::FnOnce<()>>
| +++++++++++++++++++++++++++++

error[E0493]: destructors cannot be evaluated at compile-time
--> $DIR/unstable-const-fn-in-libcore.rs:18:53
--> $DIR/unstable-const-fn-in-libcore.rs:17:53
|
LL | const fn unwrap_or_else<F: FnOnce() -> T>(self, f: F) -> T {
| ^ constant functions cannot evaluate destructors
Expand All @@ -20,7 +20,7 @@ LL | }
| - value is dropped here

error[E0493]: destructors cannot be evaluated at compile-time
--> $DIR/unstable-const-fn-in-libcore.rs:18:47
--> $DIR/unstable-const-fn-in-libcore.rs:17:47
|
LL | const fn unwrap_or_else<F: FnOnce() -> T>(self, f: F) -> T {
| ^^^^ constant functions cannot evaluate destructors
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(const_impl_trait)]
#![feature(type_alias_impl_trait)]

type Bar = impl Send;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error: `impl Send` cannot be used in patterns
--> $DIR/structural-match-no-leak.rs:15:9
--> $DIR/structural-match-no-leak.rs:14:9
|
LL | LEAK_FREE => (),
| ^^^^^^^^^
Expand Down
1 change: 0 additions & 1 deletion src/test/ui/type-alias-impl-trait/structural-match.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![feature(const_impl_trait)]
#![feature(type_alias_impl_trait)]

type Foo = impl Send;
Expand Down
2 changes: 1 addition & 1 deletion src/test/ui/type-alias-impl-trait/structural-match.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error: `impl Send` cannot be used in patterns
--> $DIR/structural-match.rs:16:9
--> $DIR/structural-match.rs:15:9
|
LL | VALUE => (),
| ^^^^^
Expand Down

0 comments on commit bb6bcaa

Please sign in to comment.