summaryrefslogtreecommitdiff
path: root/pygments/lexers/jvm.py
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2014-10-16 09:33:43 +0200
committerGeorg Brandl <georg@python.org>2014-10-16 09:33:43 +0200
commit5727fe42393a86817bd0f702d93c3fc399b68eb3 (patch)
tree796e787baf37e7362a802aaf9b6303127ff35098 /pygments/lexers/jvm.py
parentf8f38adf82e18ea5c33d532ab3429bb22eed0921 (diff)
downloadpygments-5727fe42393a86817bd0f702d93c3fc399b68eb3.tar.gz
Fix "matches empty string" complaints from regexlint.
Diffstat (limited to 'pygments/lexers/jvm.py')
-rw-r--r--pygments/lexers/jvm.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/pygments/lexers/jvm.py b/pygments/lexers/jvm.py
index df54e714..feefefc2 100644
--- a/pygments/lexers/jvm.py
+++ b/pygments/lexers/jvm.py
@@ -1462,7 +1462,8 @@ class JasminLexer(RegexLexer):
(r'(L)((?:%s[/.])*)(%s?)(;)' % (_unqualified_name, _name),
bygroups(Keyword.Type, Name.Namespace, Name.Class, Punctuation),
'#pop'),
- (r'[^%s\[)L]*' % _separator, Keyword.Type, '#pop')
+ (r'[^%s\[)L]+' % _separator, Keyword.Type, '#pop'),
+ default('#pop')
],
'descriptor/no-dots': [
include('default'),
@@ -1470,7 +1471,8 @@ class JasminLexer(RegexLexer):
(r'(L)((?:%s/)*)(%s)(;)' % (_unqualified_name, _name),
bygroups(Keyword.Type, Name.Namespace, Name.Class, Punctuation),
'#pop'),
- (r'[^%s\[)L]*' % _separator, Keyword.Type, '#pop')
+ (r'[^%s\[)L]+' % _separator, Keyword.Type, '#pop'),
+ default('#pop')
],
'descriptors/convert-dots': [
(r'\)', Punctuation, '#pop'),