Skip to content

Commit 9f1bcb6

Browse files
author
Roger Ferrer Ibanez
committedDec 1, 2016
Protect std::ostream::sentry test under libcpp-no-exceptions
Skip test that throws an exception. Differential Revision: https://reviews.llvm.org/D27255 llvm-svn: 288378
1 parent fc61769 commit 9f1bcb6

File tree

1 file changed

+4
-1
lines changed
  • libcxx/test/std/input.output/iostream.format/output.streams/ostream_sentry

1 file changed

+4
-1
lines changed
 

Diff for: ‎libcxx/test/std/input.output/iostream.format/output.streams/ostream_sentry/destruct.pass.cpp

+4-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
//
88
//===----------------------------------------------------------------------===//
99

10-
// XFAIL: libcpp-no-exceptions
1110
// <ostream>
1211

1312
// template <class charT, class traits = char_traits<charT> >
@@ -18,6 +17,8 @@
1817
#include <ostream>
1918
#include <cassert>
2019

20+
#include "test_macros.h"
21+
2122
int sync_called = 0;
2223

2324
template <class CharT>
@@ -58,6 +59,7 @@ int main()
5859
unitbuf(os);
5960
}
6061
assert(sync_called == 1);
62+
#ifndef TEST_HAS_NO_EXCEPTIONS
6163
{
6264
testbuf1<char> sb;
6365
std::ostream os(&sb);
@@ -73,4 +75,5 @@ int main()
7375
}
7476
assert(sync_called == 1);
7577
}
78+
#endif
7679
}

0 commit comments

Comments
 (0)