Address code review comments
This commit is contained in:
parent
de42ac3970
commit
cf04547b0b
27 changed files with 199 additions and 261 deletions
|
@ -627,10 +627,13 @@ fn encode_ty<'tcx>(
|
|||
}
|
||||
|
||||
// Trait types
|
||||
ty::Dynamic(predicates, region, _repr) => {
|
||||
ty::Dynamic(predicates, region, kind) => {
|
||||
// u3dynI<element-type1[..element-typeN]>E, where <element-type> is <predicate>, as
|
||||
// vendor extended type.
|
||||
let mut s = String::from("u3dynI");
|
||||
let mut s = String::from(match kind {
|
||||
ty::Dyn => "u3dynI",
|
||||
ty::DynStar => "u7dynstarI",
|
||||
});
|
||||
s.push_str(&encode_predicates(tcx, predicates, dict, options));
|
||||
s.push_str(&encode_region(tcx, *region, dict, options));
|
||||
s.push('E');
|
||||
|
|
|
@ -479,8 +479,12 @@ impl<'tcx> Printer<'tcx> for &mut SymbolMangler<'tcx> {
|
|||
})?;
|
||||
}
|
||||
|
||||
ty::Dynamic(predicates, r, _repr) => {
|
||||
self.push("D");
|
||||
ty::Dynamic(predicates, r, kind) => {
|
||||
self.push(match kind {
|
||||
ty::Dyn => "D",
|
||||
// FIXME(dyn-star): need to update v0 mangling docs
|
||||
ty::DynStar => "D*",
|
||||
});
|
||||
self = self.print_dyn_existential(predicates)?;
|
||||
self = r.print(self)?;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue