about summary refs log tree commit diff
path: root/src/test/compile-fail/variance-invariant-self-trait-match.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/compile-fail/variance-invariant-self-trait-match.rs')
-rw-r--r--src/test/compile-fail/variance-invariant-self-trait-match.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/compile-fail/variance-invariant-self-trait-match.rs b/src/test/compile-fail/variance-invariant-self-trait-match.rs
index b46cd302ae5..fe61dee23bc 100644
--- a/src/test/compile-fail/variance-invariant-self-trait-match.rs
+++ b/src/test/compile-fail/variance-invariant-self-trait-match.rs
@@ -15,13 +15,13 @@ trait Get {
 }
 
 fn get_min_from_max<'min, 'max, G>()
-    where 'max : 'min, &'max G : Get
+    where 'max : 'min, &'max G : Get, G : 'max
 {
     impls_get::<&'min G>(); //~ ERROR mismatched types
 }
 
 fn get_max_from_min<'min, 'max, G>()
-    where 'max : 'min, &'min G : Get
+    where 'max : 'min, &'min G : Get, G : 'min
 {
     impls_get::<&'max G>(); //~ ERROR mismatched types
 }