File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed
Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -318,7 +318,7 @@ function! GetHaskellIndent()
318318
319319 " newtype Foo = Foo
320320 " >>deriving
321- if l: prevline = ~ ' \C\s*\<\(newtype\|data\)\>[^{]\+' && l: line = ~ ' \C^\s*\<deriving\>'
321+ if l: prevline = ~ ' \C^ \s*\<\(newtype\|data\)\>[^{]\+' && l: line = ~ ' \C^\s*\<deriving\>'
322322 return match (l: prevline , ' \S' ) + &shiftwidth
323323 endif
324324
Original file line number Diff line number Diff line change @@ -36,7 +36,8 @@ syn match haskellTypeSig
3636 \ haskellParens
3737syn keyword haskellWhere where
3838syn keyword haskellLet let
39- syn keyword haskellDeclKeyword module class instance newtype deriving in
39+ syn match HaskellDerive " \< deriving\>\s\+\<\( anyclass\| instance\| newtype\| stock\)\? "
40+ syn keyword haskellDeclKeyword module class instance newtype in
4041syn match haskellDecl " \<\( type\| data\)\>\s\+\(\< family\>\)\? "
4142syn keyword haskellDefault default
4243syn keyword haskellImportKeywords import qualified safe as hiding contained
@@ -159,11 +160,13 @@ highlight def link haskellType Type
159160highlight def link haskellImportKeywords Include
160161if get (g: , ' haskell_classic_highlighting' , 0 )
161162 highlight def link haskellDeclKeyword Keyword
163+ highlight def link HaskellDerive Keyword
162164 highlight def link haskellDecl Keyword
163165 highlight def link haskellWhere Keyword
164166 highlight def link haskellLet Keyword
165167else
166168 highlight def link haskellDeclKeyword Structure
169+ highlight def link HaskellDerive Structure
167170 highlight def link haskellDecl Structure
168171 highlight def link haskellWhere Structure
169172 highlight def link haskellLet Structure
You can’t perform that action at this time.
0 commit comments