diff options
Diffstat (limited to 'pygments/lexers/math.py')
-rw-r--r-- | pygments/lexers/math.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/pygments/lexers/math.py b/pygments/lexers/math.py index f275d4b0..ef0555aa 100644 --- a/pygments/lexers/math.py +++ b/pygments/lexers/math.py @@ -348,13 +348,13 @@ class MatlabLexer(RegexLexer): # quote can be transpose, instead of string: # (not great, but handles common cases...) - (r'(?<=[\w\)\]])\'', Operator), + (r'(?<=[\w\)\].])\'+', Operator), (r'(\d+\.\d*|\d*\.\d+)([eEf][+-]?[0-9]+)?', Number.Float), (r'\d+[eEf][+-]?[0-9]+', Number.Float), (r'\d+', Number.Integer), - (r'(?<![\w\)\]])\'', String, 'string'), + (r'(?<![\w\)\].])\'', String, 'string'), ('[a-zA-Z_][a-zA-Z0-9_]*', Name), (r'.', Text), ], @@ -812,8 +812,8 @@ class OctaveLexer(RegexLexer): # quote can be transpose, instead of string: # (not great, but handles common cases...) - (r'(?<=[\w\)\]])\'', Operator), - (r'(?<![\w\)\]])\'', String, 'string'), + (r'(?<=[\w\)\].])\'+', Operator), + (r'(?<![\w\)\].])\'', String, 'string'), ('[a-zA-Z_][a-zA-Z0-9_]*', Name), (r'.', Text), @@ -877,8 +877,8 @@ class ScilabLexer(RegexLexer): # quote can be transpose, instead of string: # (not great, but handles common cases...) - (r'(?<=[\w\)\]])\'', Operator), - (r'(?<![\w\)\]])\'', String, 'string'), + (r'(?<=[\w\)\].])\'+', Operator), + (r'(?<![\w\)\].])\'', String, 'string'), (r'(\d+\.\d*|\d*\.\d+)([eEf][+-]?[0-9]+)?', Number.Float), (r'\d+[eEf][+-]?[0-9]+', Number.Float), |