Add parser support for generalized where clauses

Implement support in the parser for generalized where clauses,
as well as the conversion of ast::WherePredicates to
ty::Predicate in `collect.rs`.
This commit is contained in:
Jared Roesch
2014-12-20 02:29:19 -08:00
parent 8f51ad2420
commit e0cac488ac
25 changed files with 507 additions and 152 deletions

View File

@@ -129,7 +129,7 @@ impl<'a> fmt::Show for WhereClause<'a> {
try!(f.write(", ".as_bytes()));
}
let bounds = pred.bounds.as_slice();
try!(write!(f, "{}: {}", pred.name, TyParamBounds(bounds)));
try!(write!(f, "{}: {}", pred.ty, TyParamBounds(bounds)));
}
Ok(())
}