forked from OSchip/llvm-project
Remove #ifdef __FreeBSD
r220665 makes configure or CMake to set HAVE_CXXABI_H on FreeBSD 10.0. We don't need this ugly ifdef condition anymore. llvm-svn: 220666
This commit is contained in:
parent
5f3212137d
commit
fccf7ef924
|
@ -22,9 +22,7 @@
|
|||
#include "llvm/Support/FileSystem.h"
|
||||
#include "llvm/Support/Path.h"
|
||||
|
||||
// FreeBSD 10.0 has cxxabi.h but fails to define HAVE_CXXABI_H due to
|
||||
// header dependency issues.
|
||||
#if defined(HAVE_CXXABI_H) || defined (__FreeBSD__)
|
||||
#if defined(HAVE_CXXABI_H)
|
||||
#include <cxxabi.h>
|
||||
#endif
|
||||
|
||||
|
@ -274,7 +272,7 @@ std::string ELFLinkingContext::demangle(StringRef symbolName) const {
|
|||
if (!symbolName.startswith("_Z"))
|
||||
return symbolName;
|
||||
|
||||
#if defined(HAVE_CXXABI_H) || defined (__FreeBSD__)
|
||||
#if defined(HAVE_CXXABI_H)
|
||||
SmallString<256> symBuff;
|
||||
StringRef nullTermSym = Twine(symbolName).toNullTerminatedStringRef(symBuff);
|
||||
const char *cstr = nullTermSym.data();
|
||||
|
|
|
@ -27,9 +27,7 @@
|
|||
#include "llvm/Support/Path.h"
|
||||
#include <algorithm>
|
||||
|
||||
// FreeBSD 10.0 has cxxabi.h but fails to define HAVE_CXXABI_H due to
|
||||
// header dependency issues.
|
||||
#if defined(HAVE_CXXABI_H) || defined(__FreeBSD__)
|
||||
#if defined(HAVE_CXXABI_H)
|
||||
#include <cxxabi.h>
|
||||
#endif
|
||||
|
||||
|
@ -761,7 +759,7 @@ std::string MachOLinkingContext::demangle(StringRef symbolName) const {
|
|||
if (!symbolName.startswith("__Z"))
|
||||
return symbolName;
|
||||
|
||||
#if defined(HAVE_CXXABI_H) || defined(__FreeBSD__)
|
||||
#if defined(HAVE_CXXABI_H)
|
||||
SmallString<256> symBuff;
|
||||
StringRef nullTermSym = Twine(symbolName).toNullTerminatedStringRef(symBuff);
|
||||
// Mach-O has extra leading underscore that needs to be removed.
|
||||
|
|
Loading…
Reference in New Issue