]> git.proxmox.com Git - rustc.git/blobdiff - src/test/run-pass/hrtb-opt-in-copy.rs
Imported Upstream version 1.0.0-alpha.2
[rustc.git] / src / test / run-pass / hrtb-opt-in-copy.rs
index 8eaf8427bfdec9bbc680ccd0d187c60928d3dab3..7b16bb867e79c30004a1ac777e9a0c8fc2efe591 100644 (file)
@@ -18,7 +18,7 @@
 
 #![allow(dead_code)]
 
-use std::marker;
+use std::marker::PhantomData;
 
 #[derive(Copy)]
 struct Foo<T> { x: T }
@@ -26,13 +26,12 @@ struct Foo<T> { x: T }
 type Ty<'tcx> = &'tcx TyS<'tcx>;
 
 enum TyS<'tcx> {
-    Boop(marker::InvariantLifetime<'tcx>)
+    Boop(PhantomData<*mut &'tcx ()>)
 }
 
+#[derive(Copy)]
 enum Bar<'tcx> {
     Baz(Foo<Ty<'tcx>>)
 }
 
-impl<'tcx> Copy for Bar<'tcx> { }
-
 fn main() { }