Rollup merge of #37117 - pnkfelix:may-dangle-attr, r=nikomatsakis
`#[may_dangle]` attribute `#[may_dangle]` attribute Second step of #34761. Last big hurdle before we can work in earnest towards Allocator integration (#32838) Note: I am not clear if this is *also* a syntax-breaking change that needs to be part of a breaking-batch.
This commit is contained in:
@@ -1361,6 +1361,7 @@ impl<'a> State<'a> {
|
||||
if comma {
|
||||
try!(self.word_space(","))
|
||||
}
|
||||
try!(self.print_outer_attributes_inline(&lifetime_def.attrs));
|
||||
try!(self.print_lifetime_bounds(&lifetime_def.lifetime, &lifetime_def.bounds));
|
||||
comma = true;
|
||||
}
|
||||
@@ -2803,6 +2804,7 @@ impl<'a> State<'a> {
|
||||
try!(self.commasep(Inconsistent, &ints[..], |s, &idx| {
|
||||
if idx < generics.lifetimes.len() {
|
||||
let lifetime_def = &generics.lifetimes[idx];
|
||||
try!(s.print_outer_attributes_inline(&lifetime_def.attrs));
|
||||
s.print_lifetime_bounds(&lifetime_def.lifetime, &lifetime_def.bounds)
|
||||
} else {
|
||||
let idx = idx - generics.lifetimes.len();
|
||||
@@ -2816,6 +2818,7 @@ impl<'a> State<'a> {
|
||||
}
|
||||
|
||||
pub fn print_ty_param(&mut self, param: &ast::TyParam) -> io::Result<()> {
|
||||
try!(self.print_outer_attributes_inline(¶m.attrs));
|
||||
try!(self.print_ident(param.ident));
|
||||
try!(self.print_bounds(":", ¶m.bounds));
|
||||
match param.default {
|
||||
|
||||
Reference in New Issue
Block a user