summaryrefslogtreecommitdiff
path: root/src/colm.lm
diff options
context:
space:
mode:
authorAdrian Thurston <thurston@complang.org>2014-01-18 18:21:08 -0500
committerAdrian Thurston <thurston@complang.org>2014-01-18 18:21:08 -0500
commit74c213affd86ed2df6f70a37b1b63b09ef94090b (patch)
treeb70dac934a1ac6ac82c95e6083dfd0801438ba19 /src/colm.lm
parent02ce09a1e32a178707d6699bf2555ff8b164188c (diff)
downloadcolm-74c213affd86ed2df6f70a37b1b63b09ef94090b.tar.gz
new syntax for collect-ignore tokens: token <id> -
Diffstat (limited to 'src/colm.lm')
-rw-r--r--src/colm.lm8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/colm.lm b/src/colm.lm
index 35a155c2..feeec83c 100644
--- a/src/colm.lm
+++ b/src/colm.lm
@@ -72,7 +72,7 @@ lex
/ ( '0' .. '9' ) + /
token backtick_lit
- / '`' . ^( ' ' | '\n' | '\t' | ']' )* | '`]' /
+ / '`' . ^( ' ' | '\n' | '\t' | ']' )+ | '`]' /
token DQ / '\"' / ni
token SQ / '\'' / ni
@@ -196,6 +196,7 @@ def root_item
[rl_def] :Rl commit
| [literal_def] :Literal commit
| [token_def] :Token commit
+| [ic_def] :IgnoreCollector commit
| [ignore_def] :Ignore commit
| [cfl_def] :Cfl commit
| [region_def] :Region commit
@@ -241,6 +242,7 @@ def context_item
| [literal_def] :Literal commit
| [rl_def] :Rl commit
| [token_def] :Token commit
+| [ic_def] :IgnoreCollector commit
| [ignore_def] :Ignore commit
| [cfl_def] :Cfl commit
| [region_def] :Region commit
@@ -309,6 +311,7 @@ def namespace_item
[rl_def] :Rl commit
| [literal_def] :Literal commit
| [token_def] :Token commit
+| [ic_def] :IgnoreCollector commit
| [ignore_def] :Ignore commit
| [cfl_def] :Cfl commit
| [region_def] :Region commit
@@ -351,6 +354,9 @@ def token_def
NiRight: opt_no_ignore
opt_translate]
+def ic_def
+ [TOKEN id MINUS]
+
def opt_translate
[COPEN lang_stmt_list CCLOSE] :Translate
| []