aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Anderson <[email protected]>2011-04-05 20:23:52 -0400
committerBrian Anderson <[email protected]>2011-04-07 22:23:07 -0400
commit0abccc6370a6f943f9f41e6baec444dd3de2182a (patch)
tree853f3b149c7234bb6cfa2b61c4d14e8c0b36af01
parentAdd an XFAILed test for blocks that result in functions (diff)
downloadrust-0abccc6370a6f943f9f41e6baec444dd3de2182a.tar.xz
rust-0abccc6370a6f943f9f41e6baec444dd3de2182a.zip
Add a test case for calling generic functions taking alias args with box types
-rw-r--r--src/test/run-pass/generic-alias-box.rs13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/test/run-pass/generic-alias-box.rs b/src/test/run-pass/generic-alias-box.rs
new file mode 100644
index 00000000..187717a1
--- /dev/null
+++ b/src/test/run-pass/generic-alias-box.rs
@@ -0,0 +1,13 @@
+// xfail-boot
+// xfail-stage0
+
+fn id[T](&T t) -> T {
+ ret t;
+}
+
+fn main() {
+ auto expected = @100;
+ auto actual = id[@int](expected);
+ log *actual;
+ check (*expected == *actual);
+} \ No newline at end of file