diff options
Diffstat (limited to 'src/test/ui/issues/issue-46069.rs')
-rw-r--r-- | src/test/ui/issues/issue-46069.rs | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/test/ui/issues/issue-46069.rs b/src/test/ui/issues/issue-46069.rs deleted file mode 100644 index c418128c1..000000000 --- a/src/test/ui/issues/issue-46069.rs +++ /dev/null @@ -1,23 +0,0 @@ -// run-pass -use std::iter::{Fuse, Cloned}; -use std::slice::Iter; - -struct Foo<'a, T: 'a>(#[allow(unused_tuple_struct_fields)] &'a T); -impl<'a, T: 'a> Copy for Foo<'a, T> {} -impl<'a, T: 'a> Clone for Foo<'a, T> { - fn clone(&self) -> Self { *self } -} - -fn copy_ex() { - let s = 2; - let k1 = || s; - let upvar = Foo(&k1); - let k = || upvar; - k(); -} - -fn main() { - let _f: *mut <Fuse<Cloned<Iter<u8>>> as Iterator>::Item = std::ptr::null_mut(); - - copy_ex(); -} |