};
static void Warning(const Twine &Msg) { errs() << "warning: " + Msg + "\n"; }
-}
+} // anonymous namespace
/// Reset the parser state coresponding to the current object
/// file. This is to be called after an object file is finished
{MachO::N_LBRAC, "N_LBRAC"}, {MachO::N_EXCL, "N_EXCL"},
{MachO::N_RBRAC, "N_RBRAC"}, {MachO::N_BCOMM, "N_BCOMM"},
{MachO::N_ECOMM, "N_ECOMM"}, {MachO::N_ECOML, "N_ECOML"},
- {MachO::N_LENG, "N_LENG"}, {0, 0}};
+ {MachO::N_LENG, "N_LENG"}, {0, nullptr}};
static const char *getDarwinStabString(uint8_t NType) {
for (unsigned i = 0; DarwinStabNames[i].Name; i++) {
if (DarwinStabNames[i].NType == NType)
return DarwinStabNames[i].Name;
}
- return 0;
+ return nullptr;
}
void MachODebugMapParser::dumpSymTabHeader(raw_ostream &OS, StringRef Arch) {
uint32_t StringIndex, uint8_t Type,
uint8_t SectionIndex, uint16_t Flags,
uint64_t Value) {
-
// Index
OS << '[' << format_decimal(Index, 6) << "] "
// n_strx
MainBinaryStrings = MainBinary.getStringTableData();
raw_ostream &OS(llvm::outs());
- StringRef ArchName = getArchName(MainBinary);
- dumpSymTabHeader(OS, ArchName);
+ dumpSymTabHeader(OS, getArchName(MainBinary));
uint64_t Idx = 0;
for (const SymbolRef &Symbol : MainBinary.symbols()) {
const DataRefImpl &DRI = Symbol.getRawDataRefImpl();
MachODebugMapParser Parser(InputFile, Archs, PrependPath, false);
return Parser.dumpStab();
}
-}
-}
+} // namespace dsymutil
+} // namespace llvm