diff options
-rw-r--r-- | pygments/lexers/agile.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pygments/lexers/agile.py b/pygments/lexers/agile.py index d80b356a..21363d33 100644 --- a/pygments/lexers/agile.py +++ b/pygments/lexers/agile.py @@ -2281,7 +2281,7 @@ class Perl6Lexer(ExtendedRegexLexer): # in Perl 6, and also (more importantly) they are a glob deference in # Perl 5. return 0.91 - if re.search(r'sub\s+\w+:(?![(:])', text): # Special sub/method syntax (ex. sub postcircumfix:<[ ]>) + if re.search(r'sub\s+\w+:\w*[^a-zA-Z0-9{(: ]', text): # Special sub/method syntax (ex. sub postcircumfix:<[ ]>) return 0.91 for line in text.splitlines(): |