1 2 3 4 5 6
// error-pattern:attempt to use a type argument out of scope fn hd<U>(v: ~[U]) -> U { fn hd1(w: [U]) -> U { return w[0]; } return hd1(v); }