diff options
| author | Roy Frostig <[email protected]> | 2010-06-29 16:13:26 -0700 |
|---|---|---|
| committer | Roy Frostig <[email protected]> | 2010-06-29 16:13:26 -0700 |
| commit | e692ccfb0c768658f13d3cf7887efd53e14f0416 (patch) | |
| tree | e0828815c4fc90c25dcc3124f3bce3977294752c | |
| parent | Merge branch 'master' of [email protected]:graydon/rust (diff) | |
| download | rust-e692ccfb0c768658f13d3cf7887efd53e14f0416.tar.xz rust-e692ccfb0c768658f13d3cf7887efd53e14f0416.zip | |
Add (XFAILed) testcase for typechecker issue where fns-in-mods appear to lose their type parameters over the course of the typechecking pass.
| -rw-r--r-- | src/Makefile | 2 | ||||
| -rw-r--r-- | src/test/run-pass/generic-fn-twice.rs | 10 |
2 files changed, 12 insertions, 0 deletions
diff --git a/src/Makefile b/src/Makefile index 31da01b1..2c06b5f5 100644 --- a/src/Makefile +++ b/src/Makefile @@ -325,6 +325,7 @@ TEST_XFAILS_X86 := test/run-pass/mlist-cycle.rs \ test/run-pass/vec-slice.rs \ test/run-pass/fn-lval.rs \ test/run-pass/generic-fn-infer.rs \ + test/run-pass/generic-fn-twice.rs \ test/run-pass/generic-recursive-tag.rs \ test/run-pass/mutable-alias-vec.rs \ test/run-pass/mutable-vec-drop.rs \ @@ -370,6 +371,7 @@ TEST_XFAILS_LLVM := $(addprefix test/run-pass/, \ generic-drop-glue.rs \ generic-exterior-box.rs \ generic-fn-infer.rs \ + generic-fn-twice.rs \ generic-fn.rs \ generic-obj-with-derived-type.rs \ generic-obj.rs \ diff --git a/src/test/run-pass/generic-fn-twice.rs b/src/test/run-pass/generic-fn-twice.rs new file mode 100644 index 00000000..0c6257f8 --- /dev/null +++ b/src/test/run-pass/generic-fn-twice.rs @@ -0,0 +1,10 @@ +// -*- rust -*- + +mod foomod { + fn foo[T]() {} +} + +fn main() { + foomod.foo[int](); + foomod.foo[int](); +} |