diff --git a/mode/idris.py b/mode/idris.py index 087549f..f3f5187 100644 --- a/mode/idris.py +++ b/mode/idris.py @@ -31,7 +31,7 @@ class IdrisGrammar(Grammar): PatternRule(r'spaces', r'[ \t]+'), PatternRule(r'eol', r'\n'), - PatternRule(r'delimiter', r'[\[\](){},;]'), + PatternRule(r'delimiter', r'[\[\](){},;$]'), PatternRule(r'idris.xyz', r'(?:=>|->|<-|=|:)(?![-!#$%&\*\+./<=>\?@\\^|~:])'), PatternMatchRule('x', r"(module)( +)([a-zA-Z0-9_']+)", "idris.keyword", "spaces", "idris.module"), @@ -42,6 +42,7 @@ class IdrisGrammar(Grammar): RegionRule(r'string', r'"', StringGrammar, r'"'), PatternRule(r'idris.keyword', r"(?:with|where|using|try|trivial|total|then|term|syntax|solve|rewrite|refine|record|public|private|prefix|pattern|partial|parameters|of|namespace|mutual|module|let|intros|instance|infixr|infixl|infix|in|import|if|focus|exact|else|dsl|do|data|compute|codata|class|case|attack|abstract)(?![a-zA-Z0-9_'])"), + PatternRule(r'idris.builtin', "(?:_|implicit|default|auto)(?![a-zA-Z0-9_'])"), PatternRule(r'idris.name', r"['_]?[A-Z][a-zA-Z0-9_']+"), PatternRule(r'idris.word', r"[a-zA-Z0-9_']+"), @@ -85,8 +86,9 @@ class Idris(Fundamental): closetags = {')': '(', '}': '{', ']': '['} colors = { 'idris.keyword': hi_magenta, + 'idris.builtin': hi_magenta, 'idris.module': hi_yellow, - 'idris.name': hi_green, + 'idris.name': hi_blue, 'idris.xyz': hi_cyan, 'idris.directive': hi_orange, }