mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-02 16:21:11 +00:00
merge if and list
This commit is contained in:
parent
fb2281d12d
commit
d05039f295
5 changed files with 8 additions and 9 deletions
|
@ -3,20 +3,19 @@ use crate::ast::{
|
|||
};
|
||||
use crate::blankspace::{
|
||||
line_comment, space0, space0_after, space0_after_e, space0_around, space0_around_ee,
|
||||
space0_before, space0_before_e, space0_e, space1, space1_around, space1_before, spaces_exactly,
|
||||
space0_before, space0_before_e, space0_e, space1, space1_before, spaces_exactly,
|
||||
};
|
||||
use crate::ident::{global_tag_or_ident, ident, lowercase_ident, Ident};
|
||||
use crate::ident::{ident, lowercase_ident, Ident};
|
||||
use crate::keyword;
|
||||
use crate::number_literal::number_literal;
|
||||
use crate::parser::{
|
||||
self, allocated, and_then_with_indent_level, ascii_char, ascii_string, attempt, backtrackable,
|
||||
fail, map, newline_char, not, not_followed_by, optional, sep_by1, sep_by1_e, specialize,
|
||||
specialize_ref, then, unexpected, unexpected_eof, word1, word2, EExpr, ELambda, Either, If, List,
|
||||
ParseResult, Parser, State, SyntaxError, When,
|
||||
specialize_ref, then, unexpected, unexpected_eof, word1, word2, EExpr, ELambda, Either, If,
|
||||
List, ParseResult, Parser, State, SyntaxError, When,
|
||||
};
|
||||
use crate::pattern::loc_closure_param;
|
||||
use crate::type_annotation;
|
||||
use bumpalo::collections::string::String;
|
||||
use bumpalo::collections::Vec;
|
||||
use bumpalo::Bump;
|
||||
use roc_module::operator::{BinOp, CalledVia, UnaryOp};
|
||||
|
|
|
@ -1551,7 +1551,7 @@ macro_rules! collection_trailing_sep_e {
|
|||
// support empty literals containing newlines or comments, but this
|
||||
// does not seem worth even the tiniest regression in compiler performance.
|
||||
zero_or_more!($crate::parser::word1(b' ', |row, col| $space_problem(
|
||||
BadInputError::LineTooLong,
|
||||
crate::parser::BadInputError::LineTooLong,
|
||||
row,
|
||||
col
|
||||
))),
|
||||
|
|
|
@ -4,7 +4,7 @@ use crate::ident::{ident, lowercase_ident, Ident};
|
|||
use crate::number_literal::number_literal;
|
||||
use crate::parser::Progress::{self, *};
|
||||
use crate::parser::{
|
||||
backtrackable, optional, specialize, specialize_ref, word1, BadInputError, EPattern, PInParens,
|
||||
backtrackable, optional, specialize, specialize_ref, word1, EPattern, PInParens,
|
||||
PRecord, ParseResult, Parser, State, SyntaxError,
|
||||
};
|
||||
use bumpalo::collections::string::String;
|
||||
|
|
|
@ -4,7 +4,7 @@ use crate::ident::join_module_parts;
|
|||
use crate::keyword;
|
||||
use crate::parser::{
|
||||
allocated, backtrackable, not_e, optional, peek_utf8_char_e, specialize, specialize_ref, word1,
|
||||
word2, BadInputError, ParseResult, Parser,
|
||||
word2, ParseResult, Parser,
|
||||
Progress::{self, *},
|
||||
State, SyntaxError, TApply, TInParens, TRecord, TTagUnion, TVariable, Type,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue