From 4734494940f24661586728c00fa098076342abcf Mon Sep 17 00:00:00 2001 From: Jari Vetoniemi Date: Wed, 26 Sep 2018 19:00:54 +0300 Subject: fix some parsing bugs --- src/compiler/expr.lm | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src/compiler') diff --git a/src/compiler/expr.lm b/src/compiler/expr.lm index b763005..858adf4 100644 --- a/src/compiler/expr.lm +++ b/src/compiler/expr.lm @@ -23,7 +23,7 @@ context expr context paren literal `( `) - token EXPR / (any - [()]) / + token EXPR / any / def syntax [EXPR] | [`( syntax `)] @@ -37,8 +37,10 @@ context expr end context bracket - literal `[ `] `? `: - token EXPR / (any - '[' - ']' - ':') / + lex + literal `[ `] `? `: + token EXPR / any / + end def syntax [EXPR] | [`[ syntax `]] | [syntax `? syntax `: syntax] @@ -52,8 +54,10 @@ context expr end context arg - literal `( `) - token EXPR / (any - [(),]) / + lex + literal `( `) `, + token EXPR / any / + end def syntax [EXPR] | [`( syntax `)] -- cgit v1.2.3-70-g09d2