[llvm] r307530 - [DWARF] - Rename variable. NFC.

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 10 03:04:51 PDT 2017


Author: grimar
Date: Mon Jul 10 03:04:51 2017
New Revision: 307530

URL: http://llvm.org/viewvc/llvm-project?rev=307530&view=rev
Log:
[DWARF] - Rename variable. NFC.

Variable was called 'Name' and contained text
name of relocation type. Problem was that
outside of this error handling scope we already
have different 'Name' variable that contains
section name.

Change helps to avoid confusion. 

Modified:
    llvm/trunk/lib/DebugInfo/DWARF/DWARFContext.cpp

Modified: llvm/trunk/lib/DebugInfo/DWARF/DWARFContext.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/DebugInfo/DWARF/DWARFContext.cpp?rev=307530&r1=307529&r2=307530&view=diff
==============================================================================
--- llvm/trunk/lib/DebugInfo/DWARF/DWARFContext.cpp (original)
+++ llvm/trunk/lib/DebugInfo/DWARF/DWARFContext.cpp Mon Jul 10 03:04:51 2017
@@ -1042,10 +1042,10 @@ DWARFContextInMemory::DWARFContextInMemo
       object::RelocVisitor V(Obj);
       uint64_t Val = V.visit(Reloc.getType(), Reloc, SymInfoOrErr->Address);
       if (V.error()) {
-        SmallString<32> Name;
-        Reloc.getTypeName(Name);
+        SmallString<32> Type;
+        Reloc.getTypeName(Type);
         ErrorPolicy EP = HandleError(
-            createError("failed to compute relocation: " + Name + ", ",
+            createError("failed to compute relocation: " + Type + ", ",
                         errorCodeToError(object_error::parse_failed)));
         if (EP == ErrorPolicy::Halt)
           return;




More information about the llvm-commits mailing list