summaryrefslogtreecommitdiffstats
path: root/src/test/ui/drop/drop-foreign-fundamental.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/drop/drop-foreign-fundamental.rs')
-rw-r--r--src/test/ui/drop/drop-foreign-fundamental.rs23
1 files changed, 0 insertions, 23 deletions
diff --git a/src/test/ui/drop/drop-foreign-fundamental.rs b/src/test/ui/drop/drop-foreign-fundamental.rs
deleted file mode 100644
index c43df40d6..000000000
--- a/src/test/ui/drop/drop-foreign-fundamental.rs
+++ /dev/null
@@ -1,23 +0,0 @@
-use std::ops::Deref;
-use std::pin::Pin;
-
-struct Whatever<T>(T);
-
-impl<T> Deref for Whatever<T> {
- type Target = T;
-
- fn deref(&self) -> &T {
- &self.0
- }
-}
-
-struct A;
-
-impl Drop for Pin<Whatever<A>> {
- //~^ ERROR the `Drop` trait may only be implemented for local structs, enums, and unions
- fn drop(&mut self) {}
-}
-
-fn main() {
- let x = Pin::new(Whatever(1.0f32));
-}