1
Fork 0

Added support for type placeholders (explicit requested type

inference in a type with `_` ). This enables partial type inference.
This commit is contained in:
Marvin Löbel 2014-03-11 00:17:46 +01:00
parent 6c895d1d58
commit eb69eb36f8
10 changed files with 236 additions and 11 deletions

View file

@ -504,7 +504,7 @@ pub fn print_type(s: &mut State, ty: &ast::Ty) -> io::IoResult<()> {
try!(word(&mut s.s, ")"));
}
ast::TyInfer => {
fail!("print_type shouldn't see a ty_infer");
try!(word(&mut s.s, "_"));
}
}
end(s)