summaryrefslogtreecommitdiff
path: root/pygments/lexer.py
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2012-02-04 10:49:13 +0100
committerGeorg Brandl <georg@python.org>2012-02-04 10:49:13 +0100
commit7cef32ec183e53298e76304b965f1ea2c5f3577c (patch)
tree28cec35ab3f3bcf2eb8def50c49d6610356297be /pygments/lexer.py
parentd541282daa49002937f56da77ac5bb3a4b4f15c3 (diff)
parent2c1a1ade8db7b432ff2b5c42cb40f7a898c05f5d (diff)
downloadpygments-7cef32ec183e53298e76304b965f1ea2c5f3577c.tar.gz
Merge and fix ECL lexer.
Diffstat (limited to 'pygments/lexer.py')
-rw-r--r--pygments/lexer.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pygments/lexer.py b/pygments/lexer.py
index 53ea5ac1..33427ae3 100644
--- a/pygments/lexer.py
+++ b/pygments/lexer.py
@@ -439,7 +439,7 @@ class RegexLexerMeta(LexerMeta):
def __call__(cls, *args, **kwds):
"""Instantiate cls after preprocessing its token definitions."""
- if not hasattr(cls, '_tokens'):
+ if '_tokens' not in cls.__dict__:
cls._all_tokens = {}
cls._tmpname = 0
if hasattr(cls, 'token_variants') and cls.token_variants: