diff options
author | Bruce Mitchener <bruce.mitchener@gmail.com> | 2013-03-19 16:39:31 +0700 |
---|---|---|
committer | Bruce Mitchener <bruce.mitchener@gmail.com> | 2013-03-19 17:00:54 +0700 |
commit | 6fd0fa92b402c7433d8e1d95b15704281cbd25b0 (patch) | |
tree | e7053df726f17ad25db5f9d64e292f8ea69db08e | |
parent | 8754ddc7e358b04aefbb453f3d07fd597474a1bf (diff) |
When there's no exception, just drop the resume.
This addresses part of what was raised in http://llvm.org/PR15518
and issue #917.
-rw-r--r-- | src/jsifier.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/jsifier.js b/src/jsifier.js index 7db2ee70..b62bbe6c 100644 --- a/src/jsifier.js +++ b/src/jsifier.js @@ -1167,6 +1167,11 @@ function JSify(data, functionsOnly, givenFunctions) { return ret + ';'; }); makeFuncLineActor('resume', function(item) { + if (item.ident == 0) { + // No exception to resume, so we can just bail. + // This is related to issue #917 and http://llvm.org/PR15518 + return ';'; + } // If there is no current exception, set this one as it (during a resume, the current exception can be wiped out) var ptr = makeStructuralAccess(item.ident, 0); return (EXCEPTION_DEBUG ? 'Module.print("Resuming exception");' : '') + |