diff options
| author | Patrick Walton <[email protected]> | 2011-02-23 18:39:27 -0800 |
|---|---|---|
| committer | Patrick Walton <[email protected]> | 2011-02-24 12:33:08 -0800 |
| commit | 0a65283c5eeae0b98fff7d213dbaad59889e677e (patch) | |
| tree | abd9bba82b09433078eda65c62aa0a880763ac8b /src/test | |
| parent | Parse crate directive tree in one pass, then evaluate it in a second. (diff) | |
| download | rust-0a65283c5eeae0b98fff7d213dbaad59889e677e.tar.xz rust-0a65283c5eeae0b98fff7d213dbaad59889e677e.zip | |
Cast more aggressively to the callee type when calling generic functions. Add a test-case for this, and XFAIL it in rustboot.
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/run-pass/generic-fn-box.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/test/run-pass/generic-fn-box.rs b/src/test/run-pass/generic-fn-box.rs new file mode 100644 index 00000000..e821a784 --- /dev/null +++ b/src/test/run-pass/generic-fn-box.rs @@ -0,0 +1,9 @@ +fn f[T](@T x) -> @T { + ret x; +} + +fn main() { + auto x = f(@3); + log *x; +} + |