Index: src/interpreter/bytecode-generator.cc |
diff --git a/src/interpreter/bytecode-generator.cc b/src/interpreter/bytecode-generator.cc |
index ff6c9a6db26cb6c04966d5f28cb0bded8db225c6..39fbc129b1719f0f7af05a776b81658d89b5d84c 100644 |
--- a/src/interpreter/bytecode-generator.cc |
+++ b/src/interpreter/bytecode-generator.cc |
@@ -1399,7 +1399,8 @@ void BytecodeGenerator::VisitFunctionLiteral(FunctionLiteral* expr) { |
uint8_t flags = CreateClosureFlags::Encode(expr->pretenure(), |
scope()->is_function_scope()); |
size_t entry = builder()->AllocateConstantPoolEntry(); |
- builder()->CreateClosure(entry, flags); |
+ int slot_index = feedback_index(expr->LiteralFeedbackSlot()); |
+ builder()->CreateClosure(entry, slot_index, flags); |
function_literals_.push_back(std::make_pair(expr, entry)); |
} |
@@ -1530,7 +1531,8 @@ void BytecodeGenerator::BuildClassLiteralNameProperty(ClassLiteral* expr, |
void BytecodeGenerator::VisitNativeFunctionLiteral( |
NativeFunctionLiteral* expr) { |
size_t entry = builder()->AllocateConstantPoolEntry(); |
- builder()->CreateClosure(entry, NOT_TENURED); |
+ int slot_index = feedback_index(expr->LiteralFeedbackSlot()); |
+ builder()->CreateClosure(entry, slot_index, NOT_TENURED); |
native_function_literals_.push_back(std::make_pair(expr, entry)); |
} |