2015-12-30 11:54:09 +00:00
|
|
|
//===---------------------------- any.cpp ---------------------------------===//
|
2015-09-06 18:46:46 +00:00
|
|
|
//
|
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
|
//
|
|
|
|
|
// This file is dual licensed under the MIT and the University of Illinois Open
|
|
|
|
|
// Source Licenses. See LICENSE.TXT for details.
|
|
|
|
|
//
|
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
2017-01-02 19:18:58 +00:00
|
|
|
#include "any"
|
2015-09-06 18:46:46 +00:00
|
|
|
|
2017-01-02 19:18:58 +00:00
|
|
|
namespace std {
|
2015-12-30 11:54:09 +00:00
|
|
|
const char* bad_any_cast::what() const _NOEXCEPT {
|
|
|
|
|
return "bad any cast";
|
2015-09-06 18:46:46 +00:00
|
|
|
}
|
2017-01-02 19:18:58 +00:00
|
|
|
}
|
2015-12-30 11:54:09 +00:00
|
|
|
|
2018-07-28 11:07:56 +00:00
|
|
|
|
|
|
|
|
#include <experimental/__config>
|
|
|
|
|
|
|
|
|
|
// Preserve std::experimental::any_bad_cast for ABI compatibility
|
|
|
|
|
// Even though it no longer exists in a header file
|
2017-01-02 19:18:58 +00:00
|
|
|
_LIBCPP_BEGIN_NAMESPACE_LFTS
|
2018-07-28 11:07:56 +00:00
|
|
|
|
|
|
|
|
class _LIBCPP_EXCEPTION_ABI _LIBCPP_AVAILABILITY_BAD_ANY_CAST bad_any_cast : public bad_cast
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
virtual const char* what() const _NOEXCEPT;
|
|
|
|
|
};
|
|
|
|
|
|
2017-01-02 19:18:58 +00:00
|
|
|
const char* bad_any_cast::what() const _NOEXCEPT {
|
|
|
|
|
return "bad any cast";
|
|
|
|
|
}
|
2018-07-28 11:07:56 +00:00
|
|
|
|
2015-12-30 11:54:09 +00:00
|
|
|
_LIBCPP_END_NAMESPACE_LFTS
|