summaryrefslogtreecommitdiff
path: root/lld/include
diff options
context:
space:
mode:
authorLuís Ferreira <contact@lsferreira.net>2021-12-30 18:04:21 +0000
committerLuís Ferreira <contact@lsferreira.net>2021-12-30 18:04:21 +0000
commit8792cd75d0ccc0a9043b5456f147a198a9d90cd2 (patch)
tree0b3cbd7640e6c715eab8955817b3efbdab5ad517 /lld/include
parentcd997689f26d1f6558ab7a04499bd5594d09861e (diff)
downloadllvm-8792cd75d0ccc0a9043b5456f147a198a9d90cd2.tar.gz
Revert "[lld] Add support for other demanglers other than Itanium"
This reverts commit e60d6dfd5acdc821d391ad5af2c706397bdfd36a. clang-ppc64le-rhel buildbot failed (https://lab.llvm.org/buildbot#builders/57/builds/13424): tools/lld/MachO/CMakeFiles/lldMachO.dir/Symbols.cpp.o: In function `lld::demangle(llvm::StringRef, bool)': Symbols.cpp:(.text._ZN3lld8demangleEN4llvm9StringRefEb[_ZN3lld8demangleEN4llvm9StringRefEb]+0x90): undefined reference to `llvm::demangle(std::string const&)'
Diffstat (limited to 'lld/include')
-rw-r--r--lld/include/lld/Common/Strings.h11
1 files changed, 3 insertions, 8 deletions
diff --git a/lld/include/lld/Common/Strings.h b/lld/include/lld/Common/Strings.h
index ece801892767..71126f615017 100644
--- a/lld/include/lld/Common/Strings.h
+++ b/lld/include/lld/Common/Strings.h
@@ -12,19 +12,14 @@
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/Optional.h"
#include "llvm/ADT/StringRef.h"
-#include "llvm/Demangle/Demangle.h"
#include "llvm/Support/GlobPattern.h"
#include <string>
#include <vector>
namespace lld {
-// Returns a demangled symbol name. If Name is not a mangled name, it returns
-// name.
-inline std::string demangle(llvm::StringRef symName, bool shouldDemangle) {
- if (shouldDemangle)
- return llvm::demangle(symName.str().c_str());
- return std::string(symName);
-}
+// Returns a demangled C++ symbol name. If Name is not a mangled
+// name, it returns name.
+std::string demangleItanium(llvm::StringRef name);
std::vector<uint8_t> parseHex(llvm::StringRef s);
bool isValidCIdentifier(llvm::StringRef s);