Fix spacing and ordering of words in pretty printed Impl
This commit is contained in:
parent
f3df63f8ee
commit
a24e238bdf
2 changed files with 8 additions and 5 deletions
|
@ -1285,14 +1285,17 @@ impl<'a> State<'a> {
|
|||
self.print_visibility(&item.vis);
|
||||
self.print_defaultness(defaultness);
|
||||
self.print_unsafety(unsafety);
|
||||
self.word_nbsp("impl");
|
||||
self.print_constness(constness);
|
||||
self.word("impl");
|
||||
|
||||
if !generics.params.is_empty() {
|
||||
if generics.params.is_empty() {
|
||||
self.nbsp();
|
||||
} else {
|
||||
self.print_generic_params(&generics.params);
|
||||
self.space();
|
||||
}
|
||||
|
||||
self.print_constness(constness);
|
||||
|
||||
if let ast::ImplPolarity::Negative(_) = polarity {
|
||||
self.word("!");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue