diff options
Diffstat (limited to 'system')
-rw-r--r-- | system/include/emscripten/emscripten.h | 13 | ||||
-rw-r--r-- | system/include/libcxx/exception | 4 | ||||
-rw-r--r-- | system/lib/libcxx/symbols | 1 |
3 files changed, 15 insertions, 3 deletions
diff --git a/system/include/emscripten/emscripten.h b/system/include/emscripten/emscripten.h index 61634b0e..28e6063c 100644 --- a/system/include/emscripten/emscripten.h +++ b/system/include/emscripten/emscripten.h @@ -1,3 +1,6 @@ +#ifndef __emscripten_h__ +#define __emscripten_h__ + /** * This file contains a few useful things for compiling C/C++ code * with Emscripten, an LLVM-to-JavaScript compiler. @@ -136,6 +139,14 @@ inline void emscripten_async_call(void (*func)(void *), void *arg, int millis) { #endif /* + * Exits the program immediately, but leaves the runtime alive + * so that you can continue to run code later (so global destructors + * etc. are not run). This is implicitly performed when you do + * an asynchronous operation like emscripten_async_call. + */ +extern void emscripten_exit_with_live_runtime(); + +/* * Hide the OS mouse cursor over the canvas. Note that SDL's * SDL_ShowCursor command shows and hides the SDL cursor, not * the OS one. This command is useful to hide the OS cursor @@ -373,3 +384,5 @@ void emscripten_jcache_printf_(...); /* internal use */ } #endif +#endif // __emscripten_h__ + diff --git a/system/include/libcxx/exception b/system/include/libcxx/exception index 37bfc57e..102b10d6 100644 --- a/system/include/libcxx/exception +++ b/system/include/libcxx/exception @@ -91,8 +91,8 @@ class _LIBCPP_EXCEPTION_ABI exception { public: _LIBCPP_INLINE_VISIBILITY exception() _NOEXCEPT {} - virtual ~exception() _NOEXCEPT; - virtual const char* what() const _NOEXCEPT; + virtual ~exception() _NOEXCEPT {} // XXX EMSCRIPTEN - implement in header + virtual const char* what() const _NOEXCEPT { return "std::exception"; } // XXX EMSCRIPTEN - implement in header }; class _LIBCPP_EXCEPTION_ABI bad_exception diff --git a/system/lib/libcxx/symbols b/system/lib/libcxx/symbols index 93dfda65..84f4ddc9 100644 --- a/system/lib/libcxx/symbols +++ b/system/lib/libcxx/symbols @@ -2925,4 +2925,3 @@ W _ZTv0_n12_NSt3__114basic_iostreamIcNS_11char_traitsIcEEED1Ev T _ZTv0_n12_NSt3__19strstreamD0Ev T _ZTv0_n12_NSt3__19strstreamD1Ev - D llvm.global_ctors |