diff options
author | Adrian Thurston <thurston@colm.net> | 2020-04-12 11:48:15 +0000 |
---|---|---|
committer | Adrian Thurston <thurston@colm.net> | 2020-04-12 11:48:15 +0000 |
commit | 8b1810c9fd897d8d2840a0713ced1dfcfb71d109 (patch) | |
tree | 1af9de3a0d05e2a6ea507401840e75e27bfc37f6 /colm.vim | |
parent | 9760b2b3d8477ffb4228ac3db976e2ed3abb8905 (diff) | |
download | colm-8b1810c9fd897d8d2840a0713ced1dfcfb71d109.tar.gz |
first cut of a redefine statement
Redefine happens during declaration. The existing langEl is removed from the
map and a newly-declared lel replaces it. If the new list of productions
references [...] the productions from the previous lel are moved into the new
one, in its place. A copy would be preferrable, as move may require some fixup,
but move gives an initial functional implementation. refs #112
Diffstat (limited to 'colm.vim')
-rw-r--r-- | colm.vim | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -73,7 +73,7 @@ syntax match varCapture "[a-zA-Z_][a-zA-Z_0-9]*:" syntax match qual "[a-zA-Z_][a-zA-Z_0-9]*::" syntax region defTypes matchgroup=defKeywords - \ start="\<rl\>" start="\<def\>" start="\<token\>" start="\<ignore\>" + \ start="\<rl\>" start="\<def\>" start="\<redef\>" start="\<token\>" start="\<ignore\>" \ matchgroup=Function end="[a-zA-Z_][a-zA-Z0-9_]*" end="/"me=e-1 end="`"me=e-1 syntax region redTypes matchgroup=redBlock @@ -121,7 +121,7 @@ syntax keyword redKeyword throw try catch operator typeid contained syntax keyword redKeyword and bitor xor compl bitand and_eq or_eq xor_eq not not_eq contained syntax keyword redKeyword static_cast dynamic_cast contained -syntax sync match colmSyncPat grouphere NONE "([{}]|\<reduction\>|\<token\>|\<ignore\>|\<def\>)" +syntax sync match colmSyncPat grouphere NONE "([{}]|\<reduction\>|\<token\>|\<ignore\>|\<def\>|\<redef\>|{|})" " |