parameter parsing does not destroy blocks

This commit is contained in:
Aleksey Kladov
2018-08-24 20:50:37 +03:00
parent b0aac1ca98
commit f104458d45
10 changed files with 70 additions and 4 deletions

View File

@@ -1,5 +1,12 @@
use super::*;
pub(super) const PATTERN_FIRST: TokenSet =
token_set_union![
token_set![REF_KW, MUT_KW, L_PAREN, L_BRACK, AMP],
expressions::LITERAL_FIRST,
paths::PATH_FIRST,
];
pub(super) fn pattern(p: &mut Parser) {
if let Some(lhs) = atom_pat(p) {
// test range_pat