Index: src/arm64/lithium-codegen-arm64.cc |
diff --git a/src/arm64/lithium-codegen-arm64.cc b/src/arm64/lithium-codegen-arm64.cc |
index cd331db249fab802b9e00d1e400f2bc34bd0ca69..244a1e0722d5ddbe37ca89b9272682abcbd1aa77 100644 |
--- a/src/arm64/lithium-codegen-arm64.cc |
+++ b/src/arm64/lithium-codegen-arm64.cc |
@@ -703,6 +703,7 @@ bool LCodeGen::GeneratePrologue() { |
Comment(";;; Allocate local context"); |
bool need_write_barrier = true; |
// Argument to NewContext is the function, which is in x1. |
+ DCHECK(!info()->scope()->is_script_scope()); |
if (heap_slots <= FastNewContextStub::kMaximumSlots) { |
FastNewContextStub stub(isolate(), heap_slots); |
__ CallStub(&stub); |