diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-04-12 15:41:12 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-04-12 15:41:12 -0700 |
commit | 3a4bb38d59ae7008faad2a304534bb29b213e8d8 (patch) | |
tree | 9020a37e98234c2264280f3c7fd82cb9507f269a | |
parent | 1ea464d00828740ed7c898a9ac9eefdedbb2f7da (diff) |
fix __THREW__ initialization in asm.js invokes; test_exceptions now enabled and working in asm.js
-rw-r--r-- | src/jsifier.js | 4 | ||||
-rwxr-xr-x | tests/runner.py | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/jsifier.js b/src/jsifier.js index 927ffcb9..fb5e9a5f 100644 --- a/src/jsifier.js +++ b/src/jsifier.js @@ -1160,8 +1160,10 @@ function JSify(data, functionsOnly, givenFunctions) { var ret; - if (disabled || ASM_JS) { // TODO: EXCEPTION_DEBUG for asm.js + if (disabled) { ret = call_ + ';'; + } else if (ASM_JS) { + ret = '(__THREW__ = 0,' + call_ + ');'; } else { ret = '(function() { try { __THREW__ = 0; return ' + call_ + ' ' diff --git a/tests/runner.py b/tests/runner.py index fd9f7842..3c8f2d16 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -2486,7 +2486,6 @@ Exception execution path of first function! 1 ''') def test_exceptions(self): - if Settings.ASM_JS: return self.skip('no exceptions support in asm') if Settings.QUANTUM_SIZE == 1: return self.skip("we don't support libcxx in q1") if self.emcc_args is None: return self.skip('need emcc to add in libcxx properly') |