diff options
author | Georg Brandl <georg@python.org> | 2012-03-10 14:27:31 +0100 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2012-03-10 14:27:31 +0100 |
commit | c11b7995ce496ad1f0dc439187b0b8334428a78c (patch) | |
tree | ed004a956751bc1ebbb8002dc6ccb2b3a1c4f66f /pygments/lexers/math.py | |
parent | d761f76cb2491e4269638a4971dff6c26010c85f (diff) | |
parent | 08c53fd3c0e9ef11f66b9bf4dc8475677d2b7566 (diff) | |
download | pygments-c11b7995ce496ad1f0dc439187b0b8334428a78c.tar.gz |
Merged in rafaelmartins/pygments-main (pull request #60)
Diffstat (limited to 'pygments/lexers/math.py')
-rw-r--r-- | pygments/lexers/math.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pygments/lexers/math.py b/pygments/lexers/math.py index 9f7efb3b..f500231f 100644 --- a/pygments/lexers/math.py +++ b/pygments/lexers/math.py @@ -75,8 +75,8 @@ class MuPADLexer(RegexLexer): #(r'\b(?:adt|linalg|newDomain|hold)\b', Name.Builtin), (r'''(?x) ((?:[a-zA-Z_#][a-zA-Z_#0-9]*|`[^`]*`) - (?:::[a-zA-Z_#][a-zA-Z_#0-9]*|`[^`]*`)*)\s*([(])''', - bygroups(Name.Function, Punctuation)), + (?:::[a-zA-Z_#][a-zA-Z_#0-9]*|`[^`]*`)*)(\s*)([(])''', + bygroups(Name.Function, Text, Punctuation)), (r'''(?x) (?:[a-zA-Z_#][a-zA-Z_#0-9]*|`[^`]*`) (?:::[a-zA-Z_#][a-zA-Z_#0-9]*|`[^`]*`)*''', Name.Variable), @@ -668,7 +668,7 @@ class ScilabLexer(RegexLexer): _scilab_builtins.macros_kw ) + r')\b', Name.Builtin), - ("(" + "|".join(_scilab_builtins.builtin_consts) + r')\b', + (r'(%s)\b' % "|".join(map(re.escape, _scilab_builtins.builtin_consts)), Name.Constant), # operators: @@ -677,7 +677,7 @@ class ScilabLexer(RegexLexer): (r'\.\*|\*|\+|\.\^|\.\\|\.\/|\/|\\', Operator), # punctuation: - (r'[\[\](){}:@.,=:;]', Punctuation), + (r'[\[\](){}@.,=:;]', Punctuation), (r'"[^"]*"', String), |