31 #ifndef _EXCEPTION_PTR_H
32 #define _EXCEPTION_PTR_H
34 #pragma GCC visibility push(default)
37 #include <exception_defines.h>
39 #if !defined(_GLIBCXX_ATOMIC_BUILTINS_4)
40 # error This platform does not support exception propagation.
53 namespace __exception_ptr
61 using __exception_ptr::exception_ptr;
73 template<typename _Ex>
77 namespace __exception_ptr
80 operator==(
const exception_ptr&,
const exception_ptr&) throw();
83 operator!=(const exception_ptr&, const exception_ptr&) throw();
87 void* _M_exception_object;
89 explicit exception_ptr(
void* __e)
throw();
91 void _M_addref() throw();
92 void _M_release() throw();
94 void *_M_get() const throw();
96 void _M_safe_bool_dummy();
102 exception_ptr() throw();
104 typedef
void (exception_ptr::*__safe_bool)();
107 exception_ptr(__safe_bool) throw();
109 exception_ptr(const exception_ptr&) throw();
111 #ifdef __GXX_EXPERIMENTAL_CXX0X__
112 exception_ptr(exception_ptr&& __o) throw()
113 : _M_exception_object(__o._M_exception_object)
114 { __o._M_exception_object = 0; }
118 operator=(
const exception_ptr&) throw();
120 #ifdef __GXX_EXPERIMENTAL_CXX0X__
122 operator=(exception_ptr&& __o) throw()
124 exception_ptr(static_cast<exception_ptr&&>(__o)).swap(*
this);
129 ~exception_ptr() throw();
132 swap(exception_ptr&) throw();
134 #ifdef _GLIBCXX_EH_PTR_COMPAT
136 bool operator!()
const throw();
137 operator __safe_bool() const throw();
141 operator==(
const exception_ptr&,
const exception_ptr&) throw();
144 __cxa_exception_type() const throw();
150 template<typename _Ex>
169 #pragma GCC visibility pop