syntax: use lookahead to distinguish inner and outer attributes, instead of passing the latter around.
This commit is contained in:
parent
79dd393a4f
commit
9889aae13e
11 changed files with 325 additions and 512 deletions
|
@ -115,7 +115,7 @@ pub fn expand_include<'cx>(cx: &'cx mut ExtCtxt, sp: Span, tts: &[ast::TokenTree
|
|||
-> Option<SmallVector<P<ast::Item>>> {
|
||||
let mut ret = SmallVector::zero();
|
||||
while self.p.token != token::Eof {
|
||||
match self.p.parse_item_with_outer_attributes() {
|
||||
match self.p.parse_item() {
|
||||
Some(item) => ret.push(item),
|
||||
None => self.p.span_fatal(
|
||||
self.p.span,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue