try!(self.hardbreak_if_not_bol());
try!(self.maybe_print_comment(ii.span.lo));
try!(self.print_outer_attributes(&ii.attrs));
+
+ if let hir::Defaultness::Default = ii.defaultness {
+ try!(self.word_nbsp("default"));
+ }
+
match ii.node {
hir::ImplItemKind::Const(ref ty, ref expr) => {
try!(self.print_associated_const(ii.name, &ty, Some(&expr), ii.vis));
try!(self.hardbreak_if_not_bol());
try!(self.maybe_print_comment(ii.span.lo));
try!(self.print_outer_attributes(&ii.attrs));
+ if let ast::Defaultness::Default = ii.defaultness {
+ try!(self.word_nbsp("default"));
+ }
match ii.node {
ast::ImplItemKind::Const(ref ty, ref expr) => {
try!(self.print_associated_const(ii.ident, &ty, Some(&expr), ii.vis));
// / \
// Vec<i32> $Vec<i64>
-impl<T> Bar for T {} // use the provided method
+// use the provided method
+impl<T> Bar for T {}
impl Bar for i32 {
fn bar(&self) -> i32 { 1 }