summaryrefslogtreecommitdiffstats
path: root/lib/kross/python/scripts/RestrictedPython/RestrictionMutator.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/kross/python/scripts/RestrictedPython/RestrictionMutator.py')
-rw-r--r--lib/kross/python/scripts/RestrictedPython/RestrictionMutator.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/kross/python/scripts/RestrictedPython/RestrictionMutator.py b/lib/kross/python/scripts/RestrictedPython/RestrictionMutator.py
index a8b3850e0..d5f4bac02 100644
--- a/lib/kross/python/scripts/RestrictedPython/RestrictionMutator.py
+++ b/lib/kross/python/scripts/RestrictedPython/RestrictionMutator.py
@@ -26,7 +26,7 @@ from SelectCompiler import ast, parse, OP_ASSIGN, OP_DELETE, OP_APPLY
# trees without affecting line numbers shown in tracebacks, etc.
def rmLineno(node):
"""Strip lineno attributes from a code tree."""
- if node.__dict__.has_key('lineno'):
+ if 'lineno' in node.__dict__:
del node.lineno
for child in node.getChildren():
if isinstance(child, ast.Node):