[llvm-commits] [llvm] r66386 - in /llvm/trunk/lib/System: Unix/Signals.inc Win32/Signals.inc
Chris Lattner
sabre at nondot.org
Sun Mar 8 12:13:45 PDT 2009
Author: lattner
Date: Sun Mar 8 14:13:45 2009
New Revision: 66386
URL: http://llvm.org/viewvc/llvm-project?rev=66386&view=rev
Log:
add some explicit llvm:: qualifiers to the unix side, fix problems on the windows side.
Modified:
llvm/trunk/lib/System/Unix/Signals.inc
llvm/trunk/lib/System/Win32/Signals.inc
Modified: llvm/trunk/lib/System/Unix/Signals.inc
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/System/Unix/Signals.inc?rev=66386&r1=66385&r2=66386&view=diff
==============================================================================
--- llvm/trunk/lib/System/Unix/Signals.inc (original)
+++ llvm/trunk/lib/System/Unix/Signals.inc Sun Mar 8 14:13:45 2009
@@ -101,13 +101,14 @@
}
-void sys::SetInterruptFunction(void (*IF)()) {
+void llvm::sys::SetInterruptFunction(void (*IF)()) {
InterruptFunction = IF;
RegisterHandler(SIGINT);
}
// RemoveFileOnSignal - The public API
-bool sys::RemoveFileOnSignal(const sys::Path &Filename, std::string* ErrMsg) {
+bool llvm::sys::RemoveFileOnSignal(const sys::Path &Filename,
+ std::string* ErrMsg) {
if (FilesToRemove == 0)
FilesToRemove = new std::vector<sys::Path>();
@@ -121,7 +122,7 @@
/// AddSignalHandler - Add a function to be called when a signal is delivered
/// to the process. The handler can have a cookie passed to it to identify
/// what instance of the handler it is.
-void sys::AddSignalHandler(void (*FnPtr)(void *), void *Cookie) {
+void llvm::sys::AddSignalHandler(void (*FnPtr)(void *), void *Cookie) {
if (CallBacksToRun == 0)
CallBacksToRun = new std::vector<std::pair<void(*)(void*), void*> >();
CallBacksToRun->push_back(std::make_pair(FnPtr, Cookie));
@@ -187,7 +188,7 @@
/// PrintStackTraceOnErrorSignal - When an error signal (such as SIBABRT or
/// SIGSEGV) is delivered to the process, print a stack trace and then exit.
-void sys::PrintStackTraceOnErrorSignal() {
+void llvm::sys::PrintStackTraceOnErrorSignal() {
AddSignalHandler(PrintStackTrace, 0);
}
Modified: llvm/trunk/lib/System/Win32/Signals.inc
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/System/Win32/Signals.inc?rev=66386&r1=66385&r2=66386&view=diff
==============================================================================
--- llvm/trunk/lib/System/Win32/Signals.inc (original)
+++ llvm/trunk/lib/System/Win32/Signals.inc Sun Mar 8 14:13:45 2009
@@ -259,10 +259,10 @@
/// AddSignalHandler - Add a function to be called when a signal is delivered
/// to the process. The handler can have a cookie passed to it to identify
/// what instance of the handler it is.
-void sys::AddSignalHandler(void (*FnPtr)(void *), void *Cookie) {
+void llvm::sys::AddSignalHandler(void (*FnPtr)(void *), void *Cookie) {
if (CallBacksToRun == 0)
CallBacksToRun = new std::vector<std::pair<void(*)(void*), void*> >();
CallBacksToRun->push_back(std::make_pair(FnPtr, Cookie));
- std::for_each(KillSigs, KillSigsEnd, RegisterHandler);
+ RegisterHandler();
}
More information about the llvm-commits
mailing list