about summary refs log tree commit diff
path: root/src/test/compile-fail/check-static-values-constraints.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/compile-fail/check-static-values-constraints.rs')
-rw-r--r--src/test/compile-fail/check-static-values-constraints.rs19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/test/compile-fail/check-static-values-constraints.rs b/src/test/compile-fail/check-static-values-constraints.rs
index 9c6967b461a..da5f7680d8c 100644
--- a/src/test/compile-fail/check-static-values-constraints.rs
+++ b/src/test/compile-fail/check-static-values-constraints.rs
@@ -12,6 +12,7 @@
 // Verifies all possible restrictions for static items values.
 
 use std::kinds::marker;
+use std::gc::{Gc, GC};
 
 struct WithDtor;
 
@@ -95,7 +96,7 @@ static STATIC10: UnsafeStruct = UnsafeStruct;
 struct MyOwned;
 
 static STATIC11: Box<MyOwned> = box MyOwned;
-//~^ ERROR static items are not allowed to have owned pointers
+//~^ ERROR static items are not allowed to have custom pointers
 
 // The following examples test that mutable structs are just forbidden
 // to have types with destructors
@@ -113,24 +114,24 @@ static mut STATIC14: SafeStruct = SafeStruct {
 };
 
 static STATIC15: &'static [Box<MyOwned>] = &'static [box MyOwned, box MyOwned];
-//~^ ERROR static items are not allowed to have owned pointers
-//~^^ ERROR static items are not allowed to have owned pointers
+//~^ ERROR static items are not allowed to have custom pointers
+//~^^ ERROR static items are not allowed to have custom pointers
 
 static STATIC16: (&'static Box<MyOwned>, &'static Box<MyOwned>) =
     (&'static box MyOwned, &'static box MyOwned);
-//~^ ERROR static items are not allowed to have owned pointers
-//~^^ ERROR static items are not allowed to have owned pointers
+//~^ ERROR static items are not allowed to have custom pointers
+//~^^ ERROR static items are not allowed to have custom pointers
 
 static mut STATIC17: SafeEnum = Variant1;
 //~^ ERROR mutable static items are not allowed to have destructors
 
-static STATIC18: @SafeStruct = @SafeStruct{field1: Variant1, field2: Variant2(0)};
-//~^ ERROR static items are not allowed to have managed pointers
+static STATIC18: Gc<SafeStruct> = box(GC) SafeStruct{field1: Variant1, field2: Variant2(0)};
+//~^ ERROR static items are not allowed to have custom pointers
 
 static STATIC19: Box<int> = box 3;
-//~^ ERROR static items are not allowed to have owned pointers
+//~^ ERROR static items are not allowed to have custom pointers
 
 pub fn main() {
     let y = { static x: Box<int> = box 3; x };
-    //~^ ERROR static items are not allowed to have owned pointers
+    //~^ ERROR static items are not allowed to have custom pointers
 }