diff options
author | redi <redi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-05-27 11:18:37 +0000 |
---|---|---|
committer | redi <redi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-05-27 11:18:37 +0000 |
commit | 726854a8ae1321fc0ae05030b4b26642ca0eb9f6 (patch) | |
tree | 96e7e2ca94b197e4d0a70f538b776fe1cbb86b64 /libstdc++-v3/python | |
parent | 81ad436b6179ace1b03d71639d6868f644cbecb5 (diff) | |
download | gcc-726854a8ae1321fc0ae05030b4b26642ca0eb9f6.tar.gz |
PR libstdc++/66017
* include/bits/stl_tree.h (_Rb_tree_node): Use __aligned_membuf.
(_Rb_tree_iterator, _Rb_tree_const_iterator): Support construction
from _Base_ptr.
(_Rb_tree_const_iterator::_M_const_cast): Remove static_cast.
(_Rb_tree::begin, _Rb_tree::end): Remove static_cast.
* include/ext/aligned_buffer.h (__aligned_membuf): New type using
alignment of _Tp as a member subobject, not as a complete object.
* python/libstdcxx/v6/printers.py (StdRbtreeIteratorPrinter): Lookup
_Link_type manually as it might not be in the debug info.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@223745 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/python')
-rw-r--r-- | libstdc++-v3/python/libstdcxx/v6/printers.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libstdc++-v3/python/libstdcxx/v6/printers.py b/libstdc++-v3/python/libstdcxx/v6/printers.py index c6f96d737a4..2b6e4096ae4 100644 --- a/libstdc++-v3/python/libstdcxx/v6/printers.py +++ b/libstdc++-v3/python/libstdcxx/v6/printers.py @@ -456,11 +456,12 @@ class StdRbtreeIteratorPrinter: def __init__ (self, typename, val): self.val = val + valtype = self.val.type.template_argument(0).strip_typedefs() + nodetype = gdb.lookup_type('std::_Rb_tree_node<' + str(valtype) + '>') + self.link_type = nodetype.strip_typedefs().pointer() def to_string (self): - typename = str(self.val.type.strip_typedefs()) + '::_Link_type' - nodetype = gdb.lookup_type(typename).strip_typedefs() - node = self.val.cast(nodetype).dereference() + node = self.val['_M_node'].cast(self.link_type).dereference() return get_value_from_Rb_tree_node(node) class StdDebugIteratorPrinter: |