mirror of
https://github.com/intel/llvm.git
synced 2026-01-15 12:25:46 +08:00
Fixed an issue in the DWARFLocationList::Dump() function where default
arguments were quietly masked as the code changed (modified version of a path from Dawn). llvm-svn: 145216
This commit is contained in:
@@ -168,10 +168,12 @@ Stream::Address (uint64_t addr, int addr_size, const char *prefix, const char *s
|
||||
void
|
||||
Stream::AddressRange(uint64_t lo_addr, uint64_t hi_addr, int addr_size, const char *prefix, const char *suffix)
|
||||
{
|
||||
if (prefix != NULL)
|
||||
if (prefix && prefix[0])
|
||||
PutCString (prefix);
|
||||
Address (lo_addr, addr_size, "[");
|
||||
Address (hi_addr, addr_size, "-", ")");
|
||||
if (suffix && suffix[0])
|
||||
PutCString (suffix);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -34,7 +34,11 @@ DWARFLocationList::Dump(Stream &s, const DWARFCompileUnit* cu, const DataExtract
|
||||
|
||||
s.PutCString("\n ");
|
||||
s.Indent();
|
||||
s.AddressRange(start_addr + base_addr, end_addr + base_addr, NULL, ": ");
|
||||
s.AddressRange (start_addr + base_addr,
|
||||
end_addr + base_addr,
|
||||
cu->GetAddressByteSize(),
|
||||
NULL,
|
||||
": ");
|
||||
uint32_t loc_length = debug_loc_data.GetU16(&offset);
|
||||
|
||||
DataExtractor locationData(debug_loc_data, offset, loc_length);
|
||||
|
||||
Reference in New Issue
Block a user