diff options
author | Georg Brandl <georg@python.org> | 2012-02-04 09:16:28 +0100 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2012-02-04 09:16:28 +0100 |
commit | cfcc1c299170306cb93a4ddcd9b10df113e1f9f8 (patch) | |
tree | deb3c7f805f03549c9d9132ad27afd568b55bdff | |
parent | bcc5a76dd72bd7f51ccddad8cb5a7df02153e792 (diff) | |
download | pygments-cfcc1c299170306cb93a4ddcd9b10df113e1f9f8.tar.gz |
Closes #732: fix some Ada highlighting issues.
-rw-r--r-- | pygments/lexers/compiled.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/pygments/lexers/compiled.py b/pygments/lexers/compiled.py index 0e14c74b..af153a54 100644 --- a/pygments/lexers/compiled.py +++ b/pygments/lexers/compiled.py @@ -2298,7 +2298,7 @@ class AdaLexer(RegexLexer): include('numbers'), (r"'[^']'", String.Character), (r'([a-z0-9_]+)(\s*|[(,])', bygroups(Name, using(this))), - (r"(<>|=>|:=|[\(\)\|:;,.'])", Punctuation), + (r"(<>|=>|:=|[()|:;,.'])", Punctuation), (r'[*<>+=/&-]', Operator), (r'\n+', Text), ], @@ -2319,7 +2319,7 @@ class AdaLexer(RegexLexer): ], 'end' : [ ('(if|case|record|loop|select)', Keyword.Reserved), - ('"[^"]+"|[a-zA-Z0-9_]+', Name.Function), + ('"[^"]+"|[a-zA-Z0-9_.]+', Name.Function), ('[\n\s]+', Text), (';', Punctuation, '#pop'), ], @@ -2339,11 +2339,12 @@ class AdaLexer(RegexLexer): ], 'import': [ (r'[a-z0-9_.]+', Name.Namespace, '#pop'), + (r'', Text, '#pop'), ], 'formal_part' : [ (r'\)', Punctuation, '#pop'), - (r'([a-z0-9_]+)(\s*)(,|:[^=])', bygroups(Name.Variable, - Text, Punctuation)), + (r'[a-z0-9_]+', Name.Variable), + (r',|:[^=]', Punctuation), (r'(in|not|null|out|access)\b', Keyword.Reserved), include('root'), ], |