diff options
author | Emile Anclin <emile.anclin@logilab.fr> | 2010-10-28 16:07:24 +0200 |
---|---|---|
committer | Emile Anclin <emile.anclin@logilab.fr> | 2010-10-28 16:07:24 +0200 |
commit | eb563509878faba61a21aa7c0039c6314bf3cace (patch) | |
tree | 12f3fdec020fa77c12e91fa41d3803a66961c3d3 /as_string.py | |
parent | a7ef0867c87fb7d760baee8cd2b7526f238fe0b1 (diff) | |
download | astroid-eb563509878faba61a21aa7c0039c6314bf3cace.tar.gz |
py3k : introduce Nonlocal node
Diffstat (limited to 'as_string.py')
-rw-r--r-- | as_string.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/as_string.py b/as_string.py index 02a028a..7605111 100644 --- a/as_string.py +++ b/as_string.py @@ -409,6 +409,10 @@ class AsStringVisitor3k(AsStringVisitor): excs = 'except' return '%s:\n%s' % (excs, self._stmt_list(node.body)) + def visit_nonlocal(self, node): + """return an astng.Nonlocal node as string""" + return 'nonlocal %s' % ', '.join(node.names) + def visit_raise(self, node): """return an astng.Raise node as string""" if node.exc: |