diff --git a/src/opentimelineio/stringUtils.cpp b/src/opentimelineio/stringUtils.cpp index 3b3946223..3ecd47bc1 100644 --- a/src/opentimelineio/stringUtils.cpp +++ b/src/opentimelineio/stringUtils.cpp @@ -2,30 +2,9 @@ // Copyright Contributors to the OpenTimelineIO project #include "opentimelineio/serializableObject.h" -#if defined(__GNUC__) || defined(__clang__) -# include -# include -# include -#else -# include -#endif - -namespace { -#if defined(__GNUC__) || defined(__clang__) -std::string -cxxabi_type_name_for_error_mesage(const char* name) -{ - int status = -4; // some arbitrary value to eliminate the compiler warning - - std::unique_ptr res{ - abi::__cxa_demangle(name, NULL, NULL, &status), - std::free - }; - - return (status == 0) ? res.get() : name; -} -#endif -} // namespace +#include +#include +#include namespace opentimelineio { namespace OPENTIMELINEIO_VERSION { @@ -41,12 +20,7 @@ type_name_for_error_message(std::type_info const& t) return "None"; } -#if defined(__GNUC__) || defined(__clang__) - return ::cxxabi_type_name_for_error_mesage(t.name()); -#else - // On Windows std::type_info.name() returns a human readable string. return t.name(); -#endif } std::string