blob: 9c795ec250c39776e189c9d989b5f55216736201 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
// -*- rust -*-
// Issue #45: infer type parameters in function applications
fn id[T](&T x) -> T {
ret x;
}
fn main() {
let int x = 42;
let int y = id(x);
assert (x == y);
}
|