1
1
mirror of https://github.com/mawww/kakoune.git synced 2024-12-18 17:02:06 +03:00

haskell.kak: remove complex lookarounds

Highlighting is going to be slightly less correct, but we get rid
of the last incompatible regex in rc/
This commit is contained in:
Maxime Coste 2017-10-09 12:55:48 +08:00
parent d09924d24b
commit c95bd83ea1

View File

@ -45,7 +45,7 @@ add-highlighter -group /haskell/code regex \b([A-Z]['\w]*\.)*[A-Z]['\w]*(?!\.) 0
add-highlighter -group /haskell/code regex `\b([A-Z]['\w]*\.)*[\w]['\w]*` 0:operator add-highlighter -group /haskell/code regex `\b([A-Z]['\w]*\.)*[\w]['\w]*` 0:operator
# matches imported operators: M.! M.. Control.Monad.>> # matches imported operators: M.! M.. Control.Monad.>>
# not operator keywords: M... M.-> # not operator keywords: M... M.->
add-highlighter -group /haskell/code regex \b[A-Z]['\w]*\.(?!([~=|:@\\]|<-|->|=>|\.\.|::)[^~<=>|:!?/.@$*&#%+\^\-\\])[~<=>|:!?/.@$*&#%+\^\-\\]+ 0:operator add-highlighter -group /haskell/code regex \b[A-Z]['\w]*\.[~<=>|:!?/.@$*&#%+\^\-\\]+ 0:operator
# matches dot: . # matches dot: .
# not possibly incomplete import: a. # not possibly incomplete import: a.
# not other operators: !. .! # not other operators: !. .!
@ -53,7 +53,7 @@ add-highlighter -group /haskell/code regex (?<![\w~<=>|:!?/.@$*&#%+\^\-\\])\.(?!
# matches other operators: ... > < <= ^ <*> <$> etc # matches other operators: ... > < <= ^ <*> <$> etc
# not dot: . # not dot: .
# not operator keywords: @ .. -> :: ~ # not operator keywords: @ .. -> :: ~
add-highlighter -group /haskell/code regex (?<![~<=>|:!?/.@$*&#%+\^\-\\])(?!([~=|:.@\\]|<-|->|=>|\.\.|::)[^~<=>|:!?/.@$*&#%+\^\-\\])[~<=>|:!?/.@$*&#%+\^\-\\]+ 0:operator add-highlighter -group /haskell/code regex (?<![~<=>|:!?/.@$*&#%+\^\-\\])[~<=>|:!?/.@$*&#%+\^\-\\]+ 0:operator
# matches operator keywords: @ -> # matches operator keywords: @ ->
add-highlighter -group /haskell/code regex (?<![~<=>|:!?/.@$*&#%+\^\-\\])(@|~|<-|->|=>|::|=|:|[|])(?![~<=>|:!?/.@$*&#%+\^\-\\]) 1:keyword add-highlighter -group /haskell/code regex (?<![~<=>|:!?/.@$*&#%+\^\-\\])(@|~|<-|->|=>|::|=|:|[|])(?![~<=>|:!?/.@$*&#%+\^\-\\]) 1:keyword