Skip to content

Commit 1a64b48

Browse files
committed
Separate closures, async and dotuse tests in directories
1 parent b82e779 commit 1a64b48

File tree

3 files changed

+16
-10
lines changed

3 files changed

+16
-10
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
//@ check-pass
2+
//@ edition:2018
3+
4+
#![feature(ergonomic_clones)]
5+
6+
use std::future::Future;
7+
8+
fn ergonomic_clone_async_closures() -> impl Future<Output = String> {
9+
let s = String::from("hi");
10+
11+
async use {
12+
s
13+
}
14+
}
15+
16+
fn main() {}

tests/ui/ergonomic-clones/closure.rs renamed to tests/ui/ergonomic-clones/closure/basic.rs

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
//@ check-pass
2-
//@ edition:2018
32

43
#![feature(ergonomic_clones)]
54

65
use std::clone::UseCloned;
7-
use std::future::Future;
86

97
fn ergonomic_clone_closure_no_captures() -> i32 {
108
let cl = use || {
@@ -41,12 +39,4 @@ fn ergonomic_clone_closure_use_cloned() -> Foo {
4139
f
4240
}
4341

44-
fn ergonomic_clone_async_closures() -> impl Future<Output = String> {
45-
let s = String::from("hi");
46-
47-
async use {
48-
s
49-
}
50-
}
51-
5242
fn main() {}

0 commit comments

Comments
 (0)