diff options
author | Matthäus G. Chajdas <dev@anteru.net> | 2021-11-06 14:43:22 +0100 |
---|---|---|
committer | Matthäus G. Chajdas <dev@anteru.net> | 2021-11-06 14:43:22 +0100 |
commit | 906d3ce318dc057d2294909dafbab7a103513872 (patch) | |
tree | 5787ed736bde3c5c9d217338f2f7bdf422fd8b31 /pygments/lexers/matlab.py | |
parent | b7008642a14fab82f48ac027f72e27f4f8941439 (diff) | |
download | pygments-git-906d3ce318dc057d2294909dafbab7a103513872.tar.gz |
Improve SciLab lexer.
* Correctly tag whitespace
* Merge multiple whitespace tokens
* Merge multiple punctuation characters into one token
Diffstat (limited to 'pygments/lexers/matlab.py')
-rw-r--r-- | pygments/lexers/matlab.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pygments/lexers/matlab.py b/pygments/lexers/matlab.py index e12303dd..44506393 100644 --- a/pygments/lexers/matlab.py +++ b/pygments/lexers/matlab.py @@ -3262,7 +3262,7 @@ class ScilabLexer(RegexLexer): (r'\.\*|\*|\+|\.\^|\.\\|\.\/|\/|\\', Operator), # punctuation: - (r'[\[\](){}@.,=:;]', Punctuation), + (r'[\[\](){}@.,=:;]+', Punctuation), (r'"[^"]*"', String), @@ -3276,6 +3276,7 @@ class ScilabLexer(RegexLexer): (r'\d+', Number.Integer), (r'[a-zA-Z_]\w*', Name), + (r'\s+', Whitespace), (r'.', Text), ], 'string': [ |