mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-27 07:34:20 +00:00
Bug 1248416 - add symbols for bad_function_call exception for C++ runtimes. r=nfroyd
This commit is contained in:
parent
c60e0b5cc7
commit
5a00a76a1f
@ -20,9 +20,11 @@ new
|
||||
algorithm
|
||||
atomic
|
||||
deque
|
||||
functional
|
||||
ios
|
||||
iosfwd
|
||||
iostream
|
||||
istream
|
||||
iterator
|
||||
limits
|
||||
list
|
||||
|
@ -487,6 +487,7 @@ fstream
|
||||
fstream.h
|
||||
ft2build.h
|
||||
fts.h
|
||||
functional
|
||||
gconf/gconf-client.h
|
||||
Gdiplus.h
|
||||
gdk/gdk.h
|
||||
@ -565,6 +566,7 @@ ios
|
||||
iosfwd
|
||||
iostream
|
||||
iostream.h
|
||||
istream
|
||||
iterator
|
||||
JavaControl.h
|
||||
JavaEmbedding/JavaControl.h
|
||||
|
@ -54,4 +54,10 @@ moz_Xruntime_error(const char* what)
|
||||
abort_from_exception("runtime_error", what);
|
||||
}
|
||||
|
||||
MFBT_API __declspec(noreturn) void
|
||||
moz_Xbad_function_call()
|
||||
{
|
||||
abort_from_exception("bad_function_call", "bad function call");
|
||||
}
|
||||
|
||||
} // namespace std
|
||||
|
@ -12,7 +12,10 @@
|
||||
# error "Unable to wrap _RAISE(); CRT _RAISE() already defined"
|
||||
#endif
|
||||
#ifdef _XUTILITY_
|
||||
# error "Unabled to wrap _X[exception]"(); CRT versions already declared"
|
||||
# error "Unable to wrap _X[exception](); CRT versions already declared"
|
||||
#endif
|
||||
#ifdef _FUNCTIONAL_
|
||||
# error "Unable to wrap _Xbad_function_call(); CRT version already declared"
|
||||
#endif
|
||||
|
||||
#include "mozilla/mozalloc_abort.h"
|
||||
@ -26,6 +29,8 @@
|
||||
# define _Xout_of_range moz_Xout_of_range
|
||||
# define _Xoverflow_error moz_Xoverflow_error
|
||||
# define _Xruntime_error moz_Xruntime_error
|
||||
// used by <functional>
|
||||
# define _Xbad_function_call moz_Xbad_function_call
|
||||
|
||||
# include <xstddef>
|
||||
# include <xutility>
|
||||
|
@ -49,6 +49,13 @@ __throw_bad_typeid(void)
|
||||
mozalloc_abort("fatal: STL threw bad_typeid");
|
||||
}
|
||||
|
||||
// used by <functional>
|
||||
MOZ_NORETURN MOZ_ALWAYS_INLINE void
|
||||
__throw_bad_function_call(void)
|
||||
{
|
||||
mozalloc_abort("fatal: STL threw bad_function_call");
|
||||
}
|
||||
|
||||
MOZ_NORETURN MOZ_ALWAYS_INLINE void
|
||||
__throw_logic_error(const char* msg)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user