Skip to content

Commit 6141d70

Browse files
committed
Switch to remap-src-base
1 parent e36d50e commit 6141d70

File tree

2 files changed

+21
-28
lines changed

2 files changed

+21
-28
lines changed

tests/ui/iterators/iter-macro-not-async-closure.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,8 @@
11
// This test ensures iterators created with the `iter!` macro are not
22
// accidentally async closures.
33
//
4-
// We test this both in a `narrow` and `wide` configuration because
5-
// the way that the diagnostic is emitted varies depending on the
6-
// diagnostic width. If it's too narrow to fit the explanation, that
7-
// explanation is moved to the `help` instead of the span label.
8-
//
94
//@ edition: 2024
10-
//@ revisions: narrow wide
11-
//@[narrow] compile-flags: --diagnostic-width=20
12-
//@[wide] compile-flags: --diagnostic-width=300
5+
//@ remap-src-base
136

147
#![feature(yield_expr, iter_macro)]
158

tests/ui/iterators/iter-macro-not-async-closure.wide.stderr renamed to tests/ui/iterators/iter-macro-not-async-closure.stderr

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,63 +1,63 @@
1-
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}: AsyncFnOnce()` is not satisfied
2-
--> $DIR/iter-macro-not-async-closure.rs:32:34
1+
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}: AsyncFnOnce()` is not satisfied
2+
--> $DIR/iter-macro-not-async-closure.rs:25:34
33
|
44
LL | let x = pin!(call_async_once(f));
5-
| --------------- ^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}`
5+
| --------------- ^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}`
66
| |
77
| required by a bound introduced by this call
88
|
99
note: required by a bound in `call_async_once`
10-
--> $DIR/iter-macro-not-async-closure.rs:21:34
10+
--> $DIR/iter-macro-not-async-closure.rs:14:34
1111
|
1212
LL | async fn call_async_once(f: impl AsyncFnOnce()) {
1313
| ^^^^^^^^^^^^^ required by this bound in `call_async_once`
1414

15-
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}: AsyncFnOnce()` is not satisfied
16-
--> $DIR/iter-macro-not-async-closure.rs:32:18
15+
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}: AsyncFnOnce()` is not satisfied
16+
--> $DIR/iter-macro-not-async-closure.rs:25:18
1717
|
1818
LL | let x = pin!(call_async_once(f));
19-
| ^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}`
19+
| ^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}`
2020
|
2121
note: required by a bound in `call_async_once`
22-
--> $DIR/iter-macro-not-async-closure.rs:21:34
22+
--> $DIR/iter-macro-not-async-closure.rs:14:34
2323
|
2424
LL | async fn call_async_once(f: impl AsyncFnOnce()) {
2525
| ^^^^^^^^^^^^^ required by this bound in `call_async_once`
2626

27-
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}: AsyncFnOnce()` is not satisfied
28-
--> $DIR/iter-macro-not-async-closure.rs:32:13
27+
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}: AsyncFnOnce()` is not satisfied
28+
--> $DIR/iter-macro-not-async-closure.rs:25:13
2929
|
3030
LL | let x = pin!(call_async_once(f));
31-
| ^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}`
31+
| ^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}`
3232
|
3333
note: required by a bound in `call_async_once`
34-
--> $DIR/iter-macro-not-async-closure.rs:21:34
34+
--> $DIR/iter-macro-not-async-closure.rs:14:34
3535
|
3636
LL | async fn call_async_once(f: impl AsyncFnOnce()) {
3737
| ^^^^^^^^^^^^^ required by this bound in `call_async_once`
3838
= note: this error originates in the macro `pin` (in Nightly builds, run with -Z macro-backtrace for more info)
3939

40-
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}: AsyncFnOnce()` is not satisfied
41-
--> $DIR/iter-macro-not-async-closure.rs:32:13
40+
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}: AsyncFnOnce()` is not satisfied
41+
--> $DIR/iter-macro-not-async-closure.rs:25:13
4242
|
4343
LL | let x = pin!(call_async_once(f));
44-
| ^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}`
44+
| ^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}`
4545
|
4646
note: required by a bound in `call_async_once`
47-
--> $DIR/iter-macro-not-async-closure.rs:21:34
47+
--> $DIR/iter-macro-not-async-closure.rs:14:34
4848
|
4949
LL | async fn call_async_once(f: impl AsyncFnOnce()) {
5050
| ^^^^^^^^^^^^^ required by this bound in `call_async_once`
5151
= note: this error originates in the macro `pin` (in Nightly builds, run with -Z macro-backtrace for more info)
5252

53-
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}: AsyncFnOnce()` is not satisfied
54-
--> $DIR/iter-macro-not-async-closure.rs:37:5
53+
error[E0277]: the trait bound `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}: AsyncFnOnce()` is not satisfied
54+
--> $DIR/iter-macro-not-async-closure.rs:30:5
5555
|
5656
LL | x.poll(&mut Context::from_waker(Waker::noop()));
57-
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:26:21: 26:28}`
57+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `AsyncFnOnce()` is not implemented for `{gen closure@$DIR/iter-macro-not-async-closure.rs:19:21: 19:28}`
5858
|
5959
note: required by a bound in `call_async_once`
60-
--> $DIR/iter-macro-not-async-closure.rs:21:34
60+
--> $DIR/iter-macro-not-async-closure.rs:14:34
6161
|
6262
LL | async fn call_async_once(f: impl AsyncFnOnce()) {
6363
| ^^^^^^^^^^^^^ required by this bound in `call_async_once`

0 commit comments

Comments
 (0)