Author: uweigand Date: Thu Apr 14 13:31:12 2016 New Revision: 266352 URL: http://llvm.org/viewvc/llvm-project?rev=266352&view=rev Log: Fix regression in gnu_libstdcpp.py introduced by r266313
CreateChildAtOffset needs a byte offset, not an element number. Modified: lldb/trunk/examples/synthetic/gnu_libstdcpp.py Modified: lldb/trunk/examples/synthetic/gnu_libstdcpp.py URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/examples/synthetic/gnu_libstdcpp.py?rev=266352&r1=266351&r2=266352&view=diff ============================================================================== --- lldb/trunk/examples/synthetic/gnu_libstdcpp.py (original) +++ lldb/trunk/examples/synthetic/gnu_libstdcpp.py Thu Apr 14 13:31:12 2016 @@ -239,7 +239,7 @@ class StdVectorSynthProvider: return None element_type = self.start_p.GetType().GetPointeeType() element_bits = 8 * element_type.GetByteSize() - element_offset = index / element_bits + element_offset = (index / element_bits) * element_type.GetByteSize() bit_offset = index % element_bits element = self.start_p.CreateChildAtOffset('['+str(index)+']',element_offset,element_type) bit = element.GetValueAsUnsigned(0) & (1 << bit_offset) _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits