aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/src/grammar/items.rs
diff options
context:
space:
mode:
authorDJMcNab <[email protected]>2019-01-26 22:02:23 +0000
committerDJMcNab <[email protected]>2019-01-26 22:02:23 +0000
commit7055d43c3a1edca16cf5625f1b908643fa0bf21a (patch)
tree611d0fd1edff7e609b95bdceeeab5622be5eff2d /crates/ra_syntax/src/grammar/items.rs
parent55a3e21ac4cd24dd7979a44c37cd1e7a3d1b85fd (diff)
Make attrs be a child of the let statement
Diffstat (limited to 'crates/ra_syntax/src/grammar/items.rs')
-rw-r--r--crates/ra_syntax/src/grammar/items.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_syntax/src/grammar/items.rs b/crates/ra_syntax/src/grammar/items.rs
index 265e84570..18039cd3f 100644
--- a/crates/ra_syntax/src/grammar/items.rs
+++ b/crates/ra_syntax/src/grammar/items.rs
@@ -36,6 +36,7 @@ pub(super) const ITEM_RECOVERY_SET: TokenSet = token_set![
36 36
37pub(super) fn item_or_macro(p: &mut Parser, stop_on_r_curly: bool, flavor: ItemFlavor) { 37pub(super) fn item_or_macro(p: &mut Parser, stop_on_r_curly: bool, flavor: ItemFlavor) {
38 let m = p.start(); 38 let m = p.start();
39 attributes::outer_attributes(p);
39 match maybe_item(p, flavor) { 40 match maybe_item(p, flavor) {
40 MaybeItem::Item(kind) => { 41 MaybeItem::Item(kind) => {
41 m.complete(p, kind); 42 m.complete(p, kind);
@@ -79,7 +80,6 @@ pub(super) enum MaybeItem {
79} 80}
80 81
81pub(super) fn maybe_item(p: &mut Parser, flavor: ItemFlavor) -> MaybeItem { 82pub(super) fn maybe_item(p: &mut Parser, flavor: ItemFlavor) -> MaybeItem {
82 attributes::outer_attributes(p);
83 opt_visibility(p); 83 opt_visibility(p);
84 if let Some(kind) = items_without_modifiers(p) { 84 if let Some(kind) = items_without_modifiers(p) {
85 return MaybeItem::Item(kind); 85 return MaybeItem::Item(kind);