@@ -1319,6 +1319,7 @@ CompilerValue *LLVMCodeBuilder::addListItem(List *list, CompilerValue *index)
13191319 ins->functionReturnReg = ret.get ();
13201320
13211321 m_instructions.push_back (ins);
1322+ m_listInstructions.push_back (m_instructions.back ());
13221323 return addReg (ret, ins);
13231324}
13241325
@@ -1330,6 +1331,7 @@ CompilerValue *LLVMCodeBuilder::addListItemIndex(List *list, CompilerValue *item
13301331 if (m_listPtrs.find (list) == m_listPtrs.cend ())
13311332 m_listPtrs[list] = LLVMListPtr ();
13321333
1334+ m_listInstructions.push_back (m_instructions.back ());
13331335 return createOp (ins, Compiler::StaticType::Number, Compiler::StaticType::Unknown, { item });
13341336}
13351337
@@ -1341,6 +1343,7 @@ CompilerValue *LLVMCodeBuilder::addListContains(List *list, CompilerValue *item)
13411343 if (m_listPtrs.find (list) == m_listPtrs.cend ())
13421344 m_listPtrs[list] = LLVMListPtr ();
13431345
1346+ m_listInstructions.push_back (m_instructions.back ());
13441347 return createOp (ins, Compiler::StaticType::Bool, Compiler::StaticType::Unknown, { item });
13451348}
13461349
@@ -1593,6 +1596,8 @@ void LLVMCodeBuilder::createListAppend(List *list, CompilerValue *item)
15931596
15941597 if (m_listPtrs.find (list) == m_listPtrs.cend ())
15951598 m_listPtrs[list] = LLVMListPtr ();
1599+
1600+ m_listInstructions.push_back (m_instructions.back ());
15961601}
15971602
15981603void LLVMCodeBuilder::createListInsert (List *list, CompilerValue *index, CompilerValue *item)
@@ -1603,6 +1608,8 @@ void LLVMCodeBuilder::createListInsert(List *list, CompilerValue *index, Compile
16031608
16041609 if (m_listPtrs.find (list) == m_listPtrs.cend ())
16051610 m_listPtrs[list] = LLVMListPtr ();
1611+
1612+ m_listInstructions.push_back (m_instructions.back ());
16061613}
16071614
16081615void LLVMCodeBuilder::createListReplace (List *list, CompilerValue *index, CompilerValue *item)
@@ -1613,6 +1620,8 @@ void LLVMCodeBuilder::createListReplace(List *list, CompilerValue *index, Compil
16131620
16141621 if (m_listPtrs.find (list) == m_listPtrs.cend ())
16151622 m_listPtrs[list] = LLVMListPtr ();
1623+
1624+ m_listInstructions.push_back (m_instructions.back ());
16161625}
16171626
16181627void LLVMCodeBuilder::beginIfStatement (CompilerValue *cond)
0 commit comments