[LLVMSymbolize] Move printing the description of a global into a separate function...
[oota-llvm.git] / lib / DebugInfo / Symbolize / SymbolizableObjectFile.cpp
index 65d4cce3dc177d4b54a9c413e944e3189e32bbec..fb2873e8159d03bc6ff50a62f9b4510fe30c6432 100644 (file)
@@ -239,11 +239,11 @@ DIInliningInfo SymbolizableObjectFile::symbolizeInlinedCode(
   return PatchedInlinedContext;
 }
 
-bool SymbolizableObjectFile::symbolizeData(uint64_t ModuleOffset,
-                                           std::string &Name, uint64_t &Start,
-                                           uint64_t &Size) const {
-  return getNameFromSymbolTable(SymbolRef::ST_Data, ModuleOffset, Name, Start,
-                                Size);
+DIGlobal SymbolizableObjectFile::symbolizeData(uint64_t ModuleOffset) const {
+  DIGlobal Res;
+  getNameFromSymbolTable(SymbolRef::ST_Data, ModuleOffset, Res.Name, Res.Start,
+                         Res.Size);
+  return Res;
 }
 
 }  // namespace symbolize