Skip to content

Commit

Permalink
Pop function context when deindenting
Browse files Browse the repository at this point in the history
  • Loading branch information
brandon-leapyear committed Sep 23, 2021
1 parent 30b861c commit 34c4d3c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions sublime/Haskell-Custom.sublime-syntax
Original file line number Diff line number Diff line change
Expand Up @@ -293,11 +293,13 @@ contexts:
- include: fixity_declaration

function_definition:
- match: '^\s*(?!\b(let|in|case|where)\b)({{var_id}}|\({{type_id}}\))\s+(?![^\w\s=''"\(\[])(?=((([\w\.,''"_]+|(?:\w+\@)?\(.*\)|\[.*\])\s+)*))'
- match: '^(\s*)(?!\b(let|in|case|where)\b)({{var_id}}|\({{type_id}}\))\s+(?![^\w\s=''"\(\[])(?=((([\w\.,''"_]+|(?:\w+\@)?\(.*\)|\[.*\])\s+)*))'
captures:
2: entity.name.function.haskell
3: entity.name.function.haskell
push:
- meta_scope: meta.definition.function.haskell
- match: ^(?!\1\s)
pop: true
- match: '=|\|'
scope: keyword.operator.haskell
pop: true
Expand Down

0 comments on commit 34c4d3c

Please sign in to comment.