supporting LLVM trunk
This commit is contained in:
8
func.cpp
8
func.cpp
@@ -477,7 +477,11 @@ Function::GenerateIR() {
|
||||
}
|
||||
|
||||
if (m->errorCount == 0) {
|
||||
#if defined (LLVM_3_5)
|
||||
if (llvm::verifyFunction(*function) == true) {
|
||||
#else
|
||||
if (llvm::verifyFunction(*function, llvm::ReturnStatusAction) == true) {
|
||||
#endif
|
||||
if (g->debugPrint)
|
||||
function->dump();
|
||||
FATAL("Function verificication failed");
|
||||
@@ -523,8 +527,12 @@ Function::GenerateIR() {
|
||||
emitCode(&ec, appFunction, firstStmtPos);
|
||||
if (m->errorCount == 0) {
|
||||
sym->exportedFunction = appFunction;
|
||||
#if defined(LLVM_3_5)
|
||||
if (llvm::verifyFunction(*appFunction) == true) {
|
||||
#else
|
||||
if (llvm::verifyFunction(*appFunction,
|
||||
llvm::ReturnStatusAction) == true) {
|
||||
#endif
|
||||
if (g->debugPrint)
|
||||
appFunction->dump();
|
||||
FATAL("Function verificication failed");
|
||||
|
||||
Reference in New Issue
Block a user