aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Support
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Support')
-rw-r--r--lib/Support/Debug.cpp3
-rw-r--r--lib/Support/Streams.cpp1
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/Support/Debug.cpp b/lib/Support/Debug.cpp
index 6e67ed8f67..c5b6fa2bf4 100644
--- a/lib/Support/Debug.cpp
+++ b/lib/Support/Debug.cpp
@@ -69,8 +69,9 @@ bool llvm::isCurrentDebugType(const char *DebugType) {
// program from having to have hundreds of static c'tor/d'tors for them.
//
OStream &llvm::getErrorOutputStream(const char *DebugType) {
+ static OStream cnoout(0);
if (DebugFlag && isCurrentDebugType(DebugType))
return cerr;
else
- return cnull;
+ return cnoout;
}
diff --git a/lib/Support/Streams.cpp b/lib/Support/Streams.cpp
index 3d20e9aea3..433f6b4241 100644
--- a/lib/Support/Streams.cpp
+++ b/lib/Support/Streams.cpp
@@ -16,7 +16,6 @@
#include <iostream>
using namespace llvm;
-OStream llvm::cnull;
OStream llvm::cout(std::cout);
OStream llvm::cerr(std::cerr);
IStream llvm::cin(std::cin);