diff options
Diffstat (limited to 'llvm/docs/tutorial/MyFirstLanguageFrontend')
-rw-r--r-- | llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst index b517844..c5fb35d 100644 --- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst +++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst @@ -377,7 +377,7 @@ value for code that will set up the Phi node. .. code-block:: c++ // Emit else block. - TheFunction->getBasicBlockList().push_back(ElseBB); + TheFunction->insert(TheFunction->end(), ElseBB); Builder.SetInsertPoint(ElseBB); Value *ElseV = Else->codegen(); @@ -398,7 +398,7 @@ code: .. code-block:: c++ // Emit merge block. - TheFunction->getBasicBlockList().push_back(MergeBB); + TheFunction->insert(TheFunction->end(), MergeBB); Builder.SetInsertPoint(MergeBB); PHINode *PN = Builder.CreatePHI(Type::getDoubleTy(TheContext), 2, "iftmp"); |