Index: src/full-codegen/full-codegen.cc |
diff --git a/src/full-codegen/full-codegen.cc b/src/full-codegen/full-codegen.cc |
index 1b64afabe8b9fd0232ba90f052b5197fd0e91dad..657b97934b514e3d7f7faff2270e5e8f53dd1209 100644 |
--- a/src/full-codegen/full-codegen.cc |
+++ b/src/full-codegen/full-codegen.cc |
@@ -919,6 +919,7 @@ void FullCodeGenerator::EmitContinue(Statement* target) { |
// accumulator on the stack. |
ClearAccumulator(); |
while (!current->IsContinueTarget(target)) { |
+ if (HasStackOverflow()) return; |
if (current->IsTryFinally()) { |
Comment cmnt(masm(), "[ Deferred continue through finally"); |
current->Exit(&context_length); |
@@ -959,6 +960,7 @@ void FullCodeGenerator::EmitBreak(Statement* target) { |
// accumulator on the stack. |
ClearAccumulator(); |
while (!current->IsBreakTarget(target)) { |
+ if (HasStackOverflow()) return; |
if (current->IsTryFinally()) { |
Comment cmnt(masm(), "[ Deferred break through finally"); |
current->Exit(&context_length); |
@@ -994,6 +996,7 @@ void FullCodeGenerator::EmitUnwindAndReturn() { |
NestedStatement* current = nesting_stack_; |
int context_length = 0; |
while (current != NULL) { |
+ if (HasStackOverflow()) return; |
if (current->IsTryFinally()) { |
Comment cmnt(masm(), "[ Deferred return through finally"); |
current->Exit(&context_length); |