aboutsummaryrefslogtreecommitdiff
path: root/src/test/run-pass
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/run-pass')
-rw-r--r--src/test/run-pass/lib-box.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/run-pass/lib-box.rs b/src/test/run-pass/lib-box.rs
new file mode 100644
index 00000000..10f5e727
--- /dev/null
+++ b/src/test/run-pass/lib-box.rs
@@ -0,0 +1,12 @@
+use std;
+import std.Box;
+
+fn main() {
+ auto x = @3;
+ auto y = @3;
+ check (Box.ptr_eq[int](x, x));
+ check (Box.ptr_eq[int](y, y));
+ check (!Box.ptr_eq[int](x, y));
+ check (!Box.ptr_eq[int](y, x));
+}
+