better identifier and type highlighting
This commit is contained in:
parent
df038c9ce2
commit
1d90cb1382
1 changed files with 4 additions and 4 deletions
|
@ -35,14 +35,14 @@ syn keyword haskellInfix infix infixl infixr
|
|||
syn keyword haskellBottom undefined error
|
||||
syn match haskellOperators "\([-!#$%&\*\+/<=>\?@\\^|~:]\|\<_\>\)"
|
||||
syn match haskellDot "\."
|
||||
syn match haskellType "\<[A-Z][a-zA-Z0-9_]*\>"
|
||||
syn match haskellLineComment "---*\([^-!#$%&\*\+./<=>\?@\\^|~].*\)\?$" contains=@Spell
|
||||
syn match haskellChar "'[^'\\]'\|'\\.'\|'\\u[0-9a-fA-F]\{4}'"
|
||||
syn match haskellBacktick "`[A-Za-z][A-Za-z0-9_\.]*\('\)*`"
|
||||
syn match haskellBacktick "`[A-Za-z][A-Za-z0-9_\.]*'*`"
|
||||
syn region haskellString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@Spell
|
||||
syn region haskellBlockComment start="{-" end="-}" contains=haskellBlockComment,@Spell
|
||||
syn match haskellIdentifier "[_a-z][a-zA-z0-9_]*\('\)*" contained
|
||||
syn match haskellTopLevelDecl "^\s*[_a-z][a-zA-z0-9_]*\('\)*\s*::" contains=haskellIdentifier,haskellOperators
|
||||
syn match haskellIdentifier "[_a-z][a-zA-z0-9_]*'*" contained
|
||||
syn match haskellType "[A-Z][a-zA-Z0-9_]*'*"
|
||||
syn match haskellTopLevelDecl "^\s*[_a-z][a-zA-z0-9_]*'*\s*::" contains=haskellIdentifier,haskellOperators
|
||||
|
||||
if exists('g:haskell_enable_typeroles')
|
||||
syn keyword haskellTypeRoles type role phantom representational nominal contained
|
||||
|
|
Loading…
Reference in a new issue