summaryrefslogtreecommitdiff
path: root/pygments/lexers/actionscript.py
diff options
context:
space:
mode:
authorMatthäus G. Chajdas <Anteru@users.noreply.github.com>2020-09-23 18:14:24 +0200
committerGitHub <noreply@github.com>2020-09-23 18:14:24 +0200
commit9fca2a106502333db64de61f96c29cd4927c7d84 (patch)
treeb6b66be77e5481ee9bf2d47348d3993162898d2f /pygments/lexers/actionscript.py
parentf0da3b90e8eda5feb58aac2d5daa9921a88a3502 (diff)
downloadpygments-git-9fca2a106502333db64de61f96c29cd4927c7d84.tar.gz
Add analyze_text to make make check happy. (#1549)
* Add analyze_text to make make check happy. This also fixes a few small bugs: * Slash uses *.sla as the file ending, not *.sl * IDL has endelse, not elseelse * Improve various analyse_text methods. * Improve various analyse_text methods. * Make Perl less confident in presence of :=. * Improve brainfuck check to not parse the whole input. * Improve Unicon by matching \self, /self * Fix Ezhil not matching against the input text * Simplify Modula2::analyse_text.
Diffstat (limited to 'pygments/lexers/actionscript.py')
-rw-r--r--pygments/lexers/actionscript.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/pygments/lexers/actionscript.py b/pygments/lexers/actionscript.py
index e0ef3516..2a085ef7 100644
--- a/pygments/lexers/actionscript.py
+++ b/pygments/lexers/actionscript.py
@@ -110,6 +110,11 @@ class ActionScriptLexer(RegexLexer):
]
}
+ def analyse_text(text):
+ """This is only used to disambiguate between ActionScript and
+ ActionScript3. We return 0 here; the ActionScript3 lexer will match
+ AS3 variable definitions and that will hopefully suffice."""
+ return 0
class ActionScript3Lexer(RegexLexer):
"""