[PATCH] D46029: [llvm-objcopy] Implement --redefine-sym option

Jake Ehrlich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 24 15:34:03 PDT 2018


jakehehrlich added inline comments.


================
Comment at: tools/llvm-objcopy/Object.cpp:915
 
+void Object::renameSymbol(StringRef Old, StringRef New) {
+  for (auto &S : Sections)
----------------
This method isn't needed, the symbol table of an Object isn't private and (currently) there will only ever be one symbol table (the spec still ensures this). obj->SymbolTable->renameSymbol(Old, New) is sufficient to do this (with a null check since the symbol table isn't necessarily defined).


Repository:
  rL LLVM

https://reviews.llvm.org/D46029





More information about the llvm-commits mailing list