Cleanup quick_exit tests and get them passing in C++03.
Wrap the original test in _LIBCPP_HAS_QUICK_EXIT so it only runs when we have quick_exit and add two new tests that check that when _LIBCPP_HAS_QUICK_EXIT is not defined then no definition of std::at_quick_exit or std::quick_exit are available. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@222298 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -12,12 +12,13 @@
|
||||
// test quick_exit and at_quick_exit
|
||||
|
||||
#include <cstdlib>
|
||||
#include <type_traits>
|
||||
|
||||
void f() {}
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifdef _LIBCPP_HAS_QUICK_EXIT
|
||||
std::at_quick_exit(f);
|
||||
quick_exit(0);
|
||||
std::quick_exit(0);
|
||||
#endif
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user