Add StaticForeignItem and use it on ForeignItemKind
This commit is contained in:
parent
90846015cc
commit
f06e0f7837
11 changed files with 86 additions and 40 deletions
|
@ -1191,7 +1191,11 @@ impl<'a> Parser<'a> {
|
|||
ident_span: ident.span,
|
||||
const_span,
|
||||
});
|
||||
ForeignItemKind::Static(ty, Mutability::Not, expr)
|
||||
ForeignItemKind::Static(Box::new(StaticForeignItem {
|
||||
ty,
|
||||
mutability: Mutability::Not,
|
||||
expr,
|
||||
}))
|
||||
}
|
||||
_ => return self.error_bad_item_kind(span, &kind, "`extern` blocks"),
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue