From 64d07c1bd475c4945db8d7cd1fa1a61e467b079b Mon Sep 17 00:00:00 2001 From: darksv Date: Mon, 10 Sep 2018 20:14:09 +0200 Subject: Implement reparsing for remaining blocks --- crates/libsyntax2/src/grammar/expressions/atom.rs | 2 +- crates/libsyntax2/src/grammar/expressions/mod.rs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'crates/libsyntax2/src/grammar/expressions') diff --git a/crates/libsyntax2/src/grammar/expressions/atom.rs b/crates/libsyntax2/src/grammar/expressions/atom.rs index 8335c700f..f01df56bc 100644 --- a/crates/libsyntax2/src/grammar/expressions/atom.rs +++ b/crates/libsyntax2/src/grammar/expressions/atom.rs @@ -287,7 +287,7 @@ fn match_expr(p: &mut Parser) -> CompletedMarker { m.complete(p, MATCH_EXPR) } -fn match_arm_list(p: &mut Parser) { +pub(crate) fn match_arm_list(p: &mut Parser) { assert!(p.at(L_CURLY)); let m = p.start(); p.eat(L_CURLY); diff --git a/crates/libsyntax2/src/grammar/expressions/mod.rs b/crates/libsyntax2/src/grammar/expressions/mod.rs index d5ee91ad8..20e0fa328 100644 --- a/crates/libsyntax2/src/grammar/expressions/mod.rs +++ b/crates/libsyntax2/src/grammar/expressions/mod.rs @@ -2,6 +2,7 @@ mod atom; use super::*; pub(super) use self::atom::{literal, LITERAL_FIRST}; +pub(crate) use self::atom::match_arm_list; const EXPR_FIRST: TokenSet = LHS_FIRST; @@ -419,7 +420,7 @@ fn path_expr(p: &mut Parser, r: Restrictions) -> CompletedMarker { // S { x, y: 32, }; // S { x, y: 32, ..Default::default() }; // } -fn named_field_list(p: &mut Parser) { +pub(crate) fn named_field_list(p: &mut Parser) { assert!(p.at(L_CURLY)); let m = p.start(); p.bump(); -- cgit v1.2.3