diff --git a/schala-lang/language/src/parsing/new.rs b/schala-lang/language/src/parsing/new.rs index 7521ae0..181d1a3 100644 --- a/schala-lang/language/src/parsing/new.rs +++ b/schala-lang/language/src/parsing/new.rs @@ -20,6 +20,10 @@ peg::parser! { rule expression_kind() -> ExpressionKind = primary() + //TODO maybe make this more complex + rule operator() -> &'input str = + $( ['+' | '-' | '*' | '/' | '%' | '<' | '>' | '=' | '!' | '$' | '&' | '?' | '^' | '`']+ ) + rule primary() -> ExpressionKind = float_literal() / nat_literal() / bool_literal() / string_literal() / paren_expr() / list_expr()