mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 03:02:36 +01:00
[DebugInfo] Fix getPreviousSibling after r336823
llvm-svn: 336837
This commit is contained in:
parent
b0ff9a0dd3
commit
72b30ea4e0
@ -593,7 +593,8 @@ DWARFDie DWARFUnit::getPreviousSibling(const DWARFDebugInfoEntry *Die) {
|
||||
return DWARFDie();
|
||||
|
||||
// Find the previous DIE whose depth is the same as the Die's depth.
|
||||
for (size_t I = getDIEIndex(Die) - 1; I >= 0; --I) {
|
||||
for (size_t I = getDIEIndex(Die); I > 0;) {
|
||||
--I;
|
||||
if (DieArray[I].getDepth() == Depth - 1)
|
||||
return DWARFDie();
|
||||
if (DieArray[I].getDepth() == Depth)
|
||||
|
Loading…
Reference in New Issue
Block a user