diff options
Diffstat (limited to 'src/test/ui/dropck/dropck_fn_type.rs')
-rw-r--r-- | src/test/ui/dropck/dropck_fn_type.rs | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/src/test/ui/dropck/dropck_fn_type.rs b/src/test/ui/dropck/dropck_fn_type.rs deleted file mode 100644 index 2934217df..000000000 --- a/src/test/ui/dropck/dropck_fn_type.rs +++ /dev/null @@ -1,20 +0,0 @@ -// run-pass -//! Regression test for #58311, regarding the usage of Fn types in drop impls - -// All of this Drop impls should compile. - -#[allow(dead_code)] -struct S<F: Fn() -> [u8; 1]>(F); - -impl<F: Fn() -> [u8; 1]> Drop for S<F> { - fn drop(&mut self) {} -} - -#[allow(dead_code)] -struct P<A, F: FnOnce() -> [A; 10]>(F); - -impl<A, F: FnOnce() -> [A; 10]> Drop for P<A, F> { - fn drop(&mut self) {} -} - -fn main() {} |