Move /src/test to /tests
This commit is contained in:
parent
ca855e6e42
commit
cf2dff2b1e
27592 changed files with 0 additions and 0 deletions
14
tests/ui/impl-trait/closure-in-impl-trait.rs
Normal file
14
tests/ui/impl-trait/closure-in-impl-trait.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
// run-pass
|
||||
#![allow(unused_must_use)]
|
||||
fn bug<T>() -> impl Iterator<Item = [(); { |x: u32| { x }; 4 }]> {
|
||||
std::iter::empty()
|
||||
}
|
||||
|
||||
fn ok<T>() -> Box<dyn Iterator<Item = [(); { |x: u32| { x }; 4 }]>> {
|
||||
Box::new(std::iter::empty())
|
||||
}
|
||||
|
||||
fn main() {
|
||||
for _item in ok::<u32>() {}
|
||||
for _item in bug::<u32>() {}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue