diff options
author | Sylvain Thénault <sylvain.thenault@logilab.fr> | 2011-06-16 19:13:15 +0200 |
---|---|---|
committer | Sylvain Thénault <sylvain.thenault@logilab.fr> | 2011-06-16 19:13:15 +0200 |
commit | 9d8800ca5703f364518240016aaed8e5434b2472 (patch) | |
tree | 3df0b337f34920f3064980341cdadf4b60e5d93c /rebuilder.py | |
parent | db7ea8451a98b437ee635e99d83944f2a9d3acc2 (diff) | |
download | astroid-git-9d8800ca5703f364518240016aaed8e5434b2472.tar.gz |
closes #69217: please add column offset to the astng node
Diffstat (limited to 'rebuilder.py')
-rw-r--r-- | rebuilder.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/rebuilder.py b/rebuilder.py index d86013e3..69173f2a 100644 --- a/rebuilder.py +++ b/rebuilder.py @@ -117,11 +117,15 @@ def _lineno_parent(oldnode, newnode, parent): newnode.parent = parent if hasattr(oldnode, 'lineno'): newnode.lineno = oldnode.lineno + if hasattr(oldnode, 'col_offset'): + newnode.col_offset = oldnode.col_offset def _set_infos(oldnode, newnode, parent): newnode.parent = parent if hasattr(oldnode, 'lineno'): newnode.lineno = oldnode.lineno + if hasattr(oldnode, 'col_offset'): + newnode.col_offset = oldnode.col_offset newnode.set_line_info(newnode.last_child()) # set_line_info accepts None |