forked from OSchip/llvm-project
[libcxx][test] test _LIBCPP_VERSION with #ifdef, not #if
This commit is contained in:
parent
d5db25fb1d
commit
a94739985b
|
@ -24,7 +24,7 @@
|
|||
#include "test_macros.h"
|
||||
|
||||
void test(const auto& store) {
|
||||
#if _LIBCPP_VERSION
|
||||
#ifdef _LIBCPP_VERSION
|
||||
for (const auto& arg : store.__args) {
|
||||
assert(arg);
|
||||
assert(static_cast<bool>(arg));
|
||||
|
|
|
@ -145,7 +145,7 @@ void format_test_string(T world, T universe, TestFunction check,
|
|||
STR("hello {:0}"), world);
|
||||
|
||||
// *** width ***
|
||||
#if _LIBCPP_VERSION
|
||||
#ifdef _LIBCPP_VERSION
|
||||
// This limit isn't specified in the Standard.
|
||||
static_assert(std::__format::__number_max == 2'147'483'647,
|
||||
"Update the assert and the test.");
|
||||
|
@ -180,7 +180,7 @@ void format_test_string(T world, T universe, TestFunction check,
|
|||
check_exception("Invalid arg-id", STR("hello {0:{01}}"), world, 1);
|
||||
|
||||
// *** precision ***
|
||||
#if _LIBCPP_VERSION
|
||||
#ifdef _LIBCPP_VERSION
|
||||
// This limit isn't specified in the Standard.
|
||||
static_assert(std::__format::__number_max == 2'147'483'647,
|
||||
"Update the assert and the test.");
|
||||
|
|
Loading…
Reference in New Issue