Add support for atexit function, remove support for __main function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6194 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/ExecutionEngine/Interpreter/UserInput.cpp b/lib/ExecutionEngine/Interpreter/UserInput.cpp
index 0ed0f04..3f4493d 100644
--- a/lib/ExecutionEngine/Interpreter/UserInput.cpp
+++ b/lib/ExecutionEngine/Interpreter/UserInput.cpp
@@ -115,7 +115,7 @@
case Call:
std::cin >> Command;
callFunction(Command); // Enter the specified function
- finish(); // Run until it's complete
+ finish(); // Run until it's complete
break;
case TraceOpt:
@@ -129,6 +129,7 @@
}
} while (!UserQuit);
+ AtExitHandlers.clear();
}
//===----------------------------------------------------------------------===//