diff options
Diffstat (limited to 'llvm/lib/Support/Debug.cpp')
-rw-r--r-- | llvm/lib/Support/Debug.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/Support/Debug.cpp b/llvm/lib/Support/Debug.cpp index a88b18e6c06..896898c185c 100644 --- a/llvm/lib/Support/Debug.cpp +++ b/llvm/lib/Support/Debug.cpp @@ -114,9 +114,8 @@ static void debug_user_sig_handler(void *Cookie) { // know that debug mode is enabled and dbgs() really is a // circular_raw_ostream. If NDEBUG is defined, then dbgs() == // errs() but this will never be invoked. - llvm::circular_raw_ostream *dbgout = - static_cast<llvm::circular_raw_ostream *>(&llvm::dbgs()); - dbgout->flushBufferWithBanner(); + llvm::circular_raw_ostream &dbgout = cast<circular_raw_ostream>(llvm::dbgs()); + dbgout.flushBufferWithBanner(); } /// dbgs - Return a circular-buffered debug stream. |