diff options
Diffstat (limited to 'unittests/Support/raw_ostream_test.cpp')
-rw-r--r-- | unittests/Support/raw_ostream_test.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/unittests/Support/raw_ostream_test.cpp b/unittests/Support/raw_ostream_test.cpp index f87d2f60d169e..777e555949eed 100644 --- a/unittests/Support/raw_ostream_test.cpp +++ b/unittests/Support/raw_ostream_test.cpp @@ -9,6 +9,7 @@ #include "gtest/gtest.h" #include "llvm/ADT/SmallString.h" +#include "llvm/Support/FileSystem.h" #include "llvm/Support/Format.h" #include "llvm/Support/raw_ostream.h" @@ -330,4 +331,11 @@ TEST(raw_ostreamTest, FormattedHexBytes) { "0007: 68 69 6a 6b 6c |hijkl|", format_bytes_with_ascii_str(B.take_front(12), 0, 7, 1)); } + +TEST(raw_fd_ostreamTest, multiple_raw_fd_ostream_to_stdout) { + std::error_code EC; + + { raw_fd_ostream("-", EC, sys::fs::OpenFlags::F_None); } + { raw_fd_ostream("-", EC, sys::fs::OpenFlags::F_None); } +} } |