diff options
author | Adrian Thurston <thurston@complang.org> | 2012-07-21 09:36:25 -0400 |
---|---|---|
committer | Adrian Thurston <thurston@complang.org> | 2012-07-21 09:36:25 -0400 |
commit | f9935bba7998e8f6e6483a90124d86e0e16c2581 (patch) | |
tree | 3333ab3270cf5940567e4a805b224d5440d3fffa | |
parent | 6d0a84f5ff7c3b298424a771c36792a9de2154fc (diff) | |
download | colm-f9935bba7998e8f6e6483a90124d86e0e16c2581.tar.gz |
fixed order of replacement element productions
Had a code_expr ahead of a literal element in "stuff". Since code_expr allows a
string we were getting the wrong tree. Note that accum has code_expr first
because we want the strings. Going to need to sort this out!
-rw-r--r-- | src/lmparse.kl | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lmparse.kl b/src/lmparse.kl index 640c1e57..06db792c 100644 --- a/src/lmparse.kl +++ b/src/lmparse.kl @@ -725,13 +725,14 @@ repl_el: region_qual TK_Literal replItemList->append( replItem ); }; +repl_el: '"' lit_repl_el_list '"'; + repl_el: code_expr final { ReplItem *replItem = ReplItem::cons( $1->expr->loc, ReplItem::ExprType, $1->expr ); replItemList->append( replItem ); }; -repl_el: '"' lit_repl_el_list '"'; # # Accumulate List |