Path: blob/main/src/lib/libexceptions_stub.js
4150 views
/**1* @license2* Copyright 2019 The Emscripten Authors3* SPDX-License-Identifier: MIT4*/56var LibraryExceptions = {};78[9'__cxa_throw',10'__cxa_rethrow',11'llvm_eh_typeid_for',12'__cxa_begin_catch',13'__cxa_end_catch',14'__cxa_get_exception_ptr',15'_ZSt18uncaught_exceptionv',16'__cxa_call_unexpected',17'__cxa_current_primary_exception',18'__cxa_rethrow_primary_exception',19'__cxa_find_matching_catch',20'__resumeException',21].forEach((name) => {22LibraryExceptions[name] = function() { abort(); };23#if !INCLUDE_FULL_LIBRARY24// This method of link-time error generation is not compatible with INCLUDE_FULL_LIBRARY25LibraryExceptions[name + '__deps'] = [function() {26error(`DISABLE_EXCEPTION_THROWING was set (likely due to -fno-exceptions), which means no C++ exception throwing support code is linked in, but such support is required by symbol '${name}'. Either do not set DISABLE_EXCEPTION_THROWING (if you do want exception throwing) or compile all source files with -fno-exceptions (so that no exceptions support code is required); also make sure DISABLE_EXCEPTION_CATCHING is set to the right value - if you want exceptions, it should be off, and vice versa.`);27}];28#endif29});3031addToLibrary(LibraryExceptions);323334