BasicBlock *ExitBB;
};
+static void expectNoDiags(const DiagnosticInfo &DI) { EXPECT_TRUE(false); }
+
TEST_F(LinkModuleTest, BlockAddress) {
IRBuilder<> Builder(EntryBB);
Builder.CreateRet(ConstantPointerNull::get(Type::getInt8PtrTy(Ctx)));
Module *LinkedModule = new Module("MyModuleLinked", Ctx);
- Linker::linkModules(*LinkedModule, *M);
+ Linker::linkModules(*LinkedModule, *M, expectNoDiags);
// Delete the original module.
M.reset();
TEST_F(LinkModuleTest, EmptyModule) {
std::unique_ptr<Module> InternalM(getInternal(Ctx));
std::unique_ptr<Module> EmptyM(new Module("EmptyModule1", Ctx));
- Linker::linkModules(*EmptyM, *InternalM);
+ Linker::linkModules(*EmptyM, *InternalM, expectNoDiags);
}
TEST_F(LinkModuleTest, EmptyModule2) {
std::unique_ptr<Module> InternalM(getInternal(Ctx));
std::unique_ptr<Module> EmptyM(new Module("EmptyModule1", Ctx));
- Linker::linkModules(*InternalM, *EmptyM);
+ Linker::linkModules(*InternalM, *EmptyM, expectNoDiags);
}
TEST_F(LinkModuleTest, TypeMerge) {