aboutsummaryrefslogtreecommitdiff
path: root/src/library.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/library.js')
-rw-r--r--src/library.js12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/library.js b/src/library.js
index a1a3ac2f..3e337c9d 100644
--- a/src/library.js
+++ b/src/library.js
@@ -166,12 +166,22 @@ var Library = {
return 1;
},
+ // Exceptions - minimal support, only (...) for now (no actual exception objects can be caught)
+ __cxa_allocate_exception: function(size) {
+ return _malloc(size); // warning: leaked
+ },
+ __cxa_throw: function(ptr, data, dunno) {
+ throw ptr;
+ },
llvm_eh_exception: function() {
return 'code-generated exception: ' + (new Error().stack);
},
-
llvm_eh_selector: function(exception, personality, num) {
},
+ __cxa_begin_catch: function(ptr) {
+ },
+ __cxa_end_catch: function(ptr) {
+ },
__cxa_call_unexpected: function(exception) {
ABORT = true;