From 6c4dedde08686edea9a1d5173313f44ef23ee38e Mon Sep 17 00:00:00 2001 From: Mark de Wever Date: Fri, 3 May 2024 17:29:27 +0200 Subject: [PATCH] [libc++][modules] Uses _LIBCPP_USING_IF_EXISTS. (#90409) This attribute is used in the headers. Not using this in the modules has led to several issues. Add them to the modules to avoid these errors in other placed. --- libcxx/modules/std.compat/cctype.inc | 28 +- libcxx/modules/std.compat/cfenv.inc | 26 +- libcxx/modules/std.compat/cinttypes.inc | 14 +- libcxx/modules/std.compat/clocale.inc | 6 +- libcxx/modules/std.compat/cmath.inc | 372 +++++++++++------------ libcxx/modules/std.compat/csetjmp.inc | 4 +- libcxx/modules/std.compat/csignal.inc | 6 +- libcxx/modules/std.compat/cstdarg.inc | 2 +- libcxx/modules/std.compat/cstddef.inc | 6 +- libcxx/modules/std.compat/cstdint.inc | 36 +-- libcxx/modules/std.compat/cstdio.inc | 96 +++--- libcxx/modules/std.compat/cstdlib.inc | 80 ++--- libcxx/modules/std.compat/cstring.inc | 46 +-- libcxx/modules/std.compat/ctime.inc | 28 +- libcxx/modules/std.compat/cwchar.inc | 126 ++++---- libcxx/modules/std.compat/cwctype.inc | 42 +-- libcxx/modules/std/atomic.inc | 202 ++++++------- libcxx/modules/std/cctype.inc | 28 +- libcxx/modules/std/cfenv.inc | 26 +- libcxx/modules/std/cinttypes.inc | 14 +- libcxx/modules/std/clocale.inc | 6 +- libcxx/modules/std/cmath.inc | 374 ++++++++++++------------ libcxx/modules/std/csetjmp.inc | 4 +- libcxx/modules/std/csignal.inc | 6 +- libcxx/modules/std/cstdarg.inc | 2 +- libcxx/modules/std/cstddef.inc | 6 +- libcxx/modules/std/cstdint.inc | 36 +-- libcxx/modules/std/cstdio.inc | 96 +++--- libcxx/modules/std/cstdlib.inc | 86 +++--- libcxx/modules/std/cstring.inc | 46 +-- libcxx/modules/std/ctime.inc | 28 +- libcxx/modules/std/cwchar.inc | 126 ++++---- libcxx/modules/std/cwctype.inc | 42 +-- 33 files changed, 1023 insertions(+), 1023 deletions(-) diff --git a/libcxx/modules/std.compat/cctype.inc b/libcxx/modules/std.compat/cctype.inc index 56fb45a374a510..5cde12ddb38d78 100644 --- a/libcxx/modules/std.compat/cctype.inc +++ b/libcxx/modules/std.compat/cctype.inc @@ -8,18 +8,18 @@ //===----------------------------------------------------------------------===// export { - using ::isalnum; - using ::isalpha; - using ::isblank; - using ::iscntrl; - using ::isdigit; - using ::isgraph; - using ::islower; - using ::isprint; - using ::ispunct; - using ::isspace; - using ::isupper; - using ::isxdigit; - using ::tolower; - using ::toupper; + using ::isalnum _LIBCPP_USING_IF_EXISTS; + using ::isalpha _LIBCPP_USING_IF_EXISTS; + using ::isblank _LIBCPP_USING_IF_EXISTS; + using ::iscntrl _LIBCPP_USING_IF_EXISTS; + using ::isdigit _LIBCPP_USING_IF_EXISTS; + using ::isgraph _LIBCPP_USING_IF_EXISTS; + using ::islower _LIBCPP_USING_IF_EXISTS; + using ::isprint _LIBCPP_USING_IF_EXISTS; + using ::ispunct _LIBCPP_USING_IF_EXISTS; + using ::isspace _LIBCPP_USING_IF_EXISTS; + using ::isupper _LIBCPP_USING_IF_EXISTS; + using ::isxdigit _LIBCPP_USING_IF_EXISTS; + using ::tolower _LIBCPP_USING_IF_EXISTS; + using ::toupper _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cfenv.inc b/libcxx/modules/std.compat/cfenv.inc index 50128463d6a914..5a373f64697120 100644 --- a/libcxx/modules/std.compat/cfenv.inc +++ b/libcxx/modules/std.compat/cfenv.inc @@ -9,21 +9,21 @@ export { // types - using ::fenv_t; - using ::fexcept_t; + using ::fenv_t _LIBCPP_USING_IF_EXISTS; + using ::fexcept_t _LIBCPP_USING_IF_EXISTS; // functions - using ::feclearexcept; - using ::fegetexceptflag; - using ::feraiseexcept; - using ::fesetexceptflag; - using ::fetestexcept; + using ::feclearexcept _LIBCPP_USING_IF_EXISTS; + using ::fegetexceptflag _LIBCPP_USING_IF_EXISTS; + using ::feraiseexcept _LIBCPP_USING_IF_EXISTS; + using ::fesetexceptflag _LIBCPP_USING_IF_EXISTS; + using ::fetestexcept _LIBCPP_USING_IF_EXISTS; - using ::fegetround; - using ::fesetround; + using ::fegetround _LIBCPP_USING_IF_EXISTS; + using ::fesetround _LIBCPP_USING_IF_EXISTS; - using ::fegetenv; - using ::feholdexcept; - using ::fesetenv; - using ::feupdateenv; + using ::fegetenv _LIBCPP_USING_IF_EXISTS; + using ::feholdexcept _LIBCPP_USING_IF_EXISTS; + using ::fesetenv _LIBCPP_USING_IF_EXISTS; + using ::feupdateenv _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cinttypes.inc b/libcxx/modules/std.compat/cinttypes.inc index a64c088d0d6f88..4789ec33102008 100644 --- a/libcxx/modules/std.compat/cinttypes.inc +++ b/libcxx/modules/std.compat/cinttypes.inc @@ -8,14 +8,14 @@ //===----------------------------------------------------------------------===// export { - using ::imaxdiv_t; + using ::imaxdiv_t _LIBCPP_USING_IF_EXISTS; - using ::imaxabs; - using ::imaxdiv; - using ::strtoimax; - using ::strtoumax; - using ::wcstoimax; - using ::wcstoumax; + using ::imaxabs _LIBCPP_USING_IF_EXISTS; + using ::imaxdiv _LIBCPP_USING_IF_EXISTS; + using ::strtoimax _LIBCPP_USING_IF_EXISTS; + using ::strtoumax _LIBCPP_USING_IF_EXISTS; + using ::wcstoimax _LIBCPP_USING_IF_EXISTS; + using ::wcstoumax _LIBCPP_USING_IF_EXISTS; // abs is conditionally here, but always present in cmath.cppm. To avoid // conflicing declarations omit the using here. diff --git a/libcxx/modules/std.compat/clocale.inc b/libcxx/modules/std.compat/clocale.inc index d9785a73794300..1a975c560a496d 100644 --- a/libcxx/modules/std.compat/clocale.inc +++ b/libcxx/modules/std.compat/clocale.inc @@ -9,9 +9,9 @@ export { #ifndef _LIBCPP_HAS_NO_LOCALIZATION - using ::lconv; + using ::lconv _LIBCPP_USING_IF_EXISTS; - using ::localeconv; - using ::setlocale; + using ::localeconv _LIBCPP_USING_IF_EXISTS; + using ::setlocale _LIBCPP_USING_IF_EXISTS; #endif // _LIBCPP_HAS_NO_LOCALIZATION } // export diff --git a/libcxx/modules/std.compat/cmath.inc b/libcxx/modules/std.compat/cmath.inc index de5379275c5fae..6c86d0df574062 100644 --- a/libcxx/modules/std.compat/cmath.inc +++ b/libcxx/modules/std.compat/cmath.inc @@ -8,241 +8,241 @@ //===----------------------------------------------------------------------===// export { - using ::double_t; - using ::float_t; + using ::double_t _LIBCPP_USING_IF_EXISTS; + using ::float_t _LIBCPP_USING_IF_EXISTS; - using ::acos; - using ::acosf; - using ::acosl; + using ::acos _LIBCPP_USING_IF_EXISTS; + using ::acosf _LIBCPP_USING_IF_EXISTS; + using ::acosl _LIBCPP_USING_IF_EXISTS; - using ::asin; - using ::asinf; - using ::asinl; + using ::asin _LIBCPP_USING_IF_EXISTS; + using ::asinf _LIBCPP_USING_IF_EXISTS; + using ::asinl _LIBCPP_USING_IF_EXISTS; - using ::atan; - using ::atanf; - using ::atanl; + using ::atan _LIBCPP_USING_IF_EXISTS; + using ::atanf _LIBCPP_USING_IF_EXISTS; + using ::atanl _LIBCPP_USING_IF_EXISTS; - using ::atan2; - using ::atan2f; - using ::atan2l; + using ::atan2 _LIBCPP_USING_IF_EXISTS; + using ::atan2f _LIBCPP_USING_IF_EXISTS; + using ::atan2l _LIBCPP_USING_IF_EXISTS; - using ::cos; - using ::cosf; - using ::cosl; + using ::cos _LIBCPP_USING_IF_EXISTS; + using ::cosf _LIBCPP_USING_IF_EXISTS; + using ::cosl _LIBCPP_USING_IF_EXISTS; - using ::sin; - using ::sinf; - using ::sinl; + using ::sin _LIBCPP_USING_IF_EXISTS; + using ::sinf _LIBCPP_USING_IF_EXISTS; + using ::sinl _LIBCPP_USING_IF_EXISTS; - using ::tan; - using ::tanf; - using ::tanl; + using ::tan _LIBCPP_USING_IF_EXISTS; + using ::tanf _LIBCPP_USING_IF_EXISTS; + using ::tanl _LIBCPP_USING_IF_EXISTS; - using ::acosh; - using ::acoshf; - using ::acoshl; + using ::acosh _LIBCPP_USING_IF_EXISTS; + using ::acoshf _LIBCPP_USING_IF_EXISTS; + using ::acoshl _LIBCPP_USING_IF_EXISTS; - using ::asinh; - using ::asinhf; - using ::asinhl; + using ::asinh _LIBCPP_USING_IF_EXISTS; + using ::asinhf _LIBCPP_USING_IF_EXISTS; + using ::asinhl _LIBCPP_USING_IF_EXISTS; - using ::atanh; - using ::atanhf; - using ::atanhl; + using ::atanh _LIBCPP_USING_IF_EXISTS; + using ::atanhf _LIBCPP_USING_IF_EXISTS; + using ::atanhl _LIBCPP_USING_IF_EXISTS; - using ::cosh; - using ::coshf; - using ::coshl; + using ::cosh _LIBCPP_USING_IF_EXISTS; + using ::coshf _LIBCPP_USING_IF_EXISTS; + using ::coshl _LIBCPP_USING_IF_EXISTS; - using ::sinh; - using ::sinhf; - using ::sinhl; + using ::sinh _LIBCPP_USING_IF_EXISTS; + using ::sinhf _LIBCPP_USING_IF_EXISTS; + using ::sinhl _LIBCPP_USING_IF_EXISTS; - using ::tanh; - using ::tanhf; - using ::tanhl; + using ::tanh _LIBCPP_USING_IF_EXISTS; + using ::tanhf _LIBCPP_USING_IF_EXISTS; + using ::tanhl _LIBCPP_USING_IF_EXISTS; - using ::exp; - using ::expf; - using ::expl; + using ::exp _LIBCPP_USING_IF_EXISTS; + using ::expf _LIBCPP_USING_IF_EXISTS; + using ::expl _LIBCPP_USING_IF_EXISTS; - using ::exp2; - using ::exp2f; - using ::exp2l; + using ::exp2 _LIBCPP_USING_IF_EXISTS; + using ::exp2f _LIBCPP_USING_IF_EXISTS; + using ::exp2l _LIBCPP_USING_IF_EXISTS; - using ::expm1; - using ::expm1f; - using ::expm1l; + using ::expm1 _LIBCPP_USING_IF_EXISTS; + using ::expm1f _LIBCPP_USING_IF_EXISTS; + using ::expm1l _LIBCPP_USING_IF_EXISTS; - using ::frexp; - using ::frexpf; - using ::frexpl; + using ::frexp _LIBCPP_USING_IF_EXISTS; + using ::frexpf _LIBCPP_USING_IF_EXISTS; + using ::frexpl _LIBCPP_USING_IF_EXISTS; - using ::ilogb; - using ::ilogbf; - using ::ilogbl; + using ::ilogb _LIBCPP_USING_IF_EXISTS; + using ::ilogbf _LIBCPP_USING_IF_EXISTS; + using ::ilogbl _LIBCPP_USING_IF_EXISTS; - using ::ldexp; - using ::ldexpf; - using ::ldexpl; + using ::ldexp _LIBCPP_USING_IF_EXISTS; + using ::ldexpf _LIBCPP_USING_IF_EXISTS; + using ::ldexpl _LIBCPP_USING_IF_EXISTS; - using ::log; - using ::logf; - using ::logl; + using ::log _LIBCPP_USING_IF_EXISTS; + using ::logf _LIBCPP_USING_IF_EXISTS; + using ::logl _LIBCPP_USING_IF_EXISTS; - using ::log10; - using ::log10f; - using ::log10l; + using ::log10 _LIBCPP_USING_IF_EXISTS; + using ::log10f _LIBCPP_USING_IF_EXISTS; + using ::log10l _LIBCPP_USING_IF_EXISTS; - using ::log1p; - using ::log1pf; - using ::log1pl; + using ::log1p _LIBCPP_USING_IF_EXISTS; + using ::log1pf _LIBCPP_USING_IF_EXISTS; + using ::log1pl _LIBCPP_USING_IF_EXISTS; - using ::log2; - using ::log2f; - using ::log2l; + using ::log2 _LIBCPP_USING_IF_EXISTS; + using ::log2f _LIBCPP_USING_IF_EXISTS; + using ::log2l _LIBCPP_USING_IF_EXISTS; - using ::logb; - using ::logbf; - using ::logbl; + using ::logb _LIBCPP_USING_IF_EXISTS; + using ::logbf _LIBCPP_USING_IF_EXISTS; + using ::logbl _LIBCPP_USING_IF_EXISTS; - using ::modf; - using ::modff; - using ::modfl; + using ::modf _LIBCPP_USING_IF_EXISTS; + using ::modff _LIBCPP_USING_IF_EXISTS; + using ::modfl _LIBCPP_USING_IF_EXISTS; - using ::scalbn; - using ::scalbnf; - using ::scalbnl; + using ::scalbn _LIBCPP_USING_IF_EXISTS; + using ::scalbnf _LIBCPP_USING_IF_EXISTS; + using ::scalbnl _LIBCPP_USING_IF_EXISTS; - using ::scalbln; - using ::scalblnf; - using ::scalblnl; + using ::scalbln _LIBCPP_USING_IF_EXISTS; + using ::scalblnf _LIBCPP_USING_IF_EXISTS; + using ::scalblnl _LIBCPP_USING_IF_EXISTS; - using ::cbrt; - using ::cbrtf; - using ::cbrtl; + using ::cbrt _LIBCPP_USING_IF_EXISTS; + using ::cbrtf _LIBCPP_USING_IF_EXISTS; + using ::cbrtl _LIBCPP_USING_IF_EXISTS; // [c.math.abs], absolute values - using ::abs; + using ::abs _LIBCPP_USING_IF_EXISTS; - using ::fabs; - using ::fabsf; - using ::fabsl; + using ::fabs _LIBCPP_USING_IF_EXISTS; + using ::fabsf _LIBCPP_USING_IF_EXISTS; + using ::fabsl _LIBCPP_USING_IF_EXISTS; - using ::hypot; - using ::hypotf; - using ::hypotl; + using ::hypot _LIBCPP_USING_IF_EXISTS; + using ::hypotf _LIBCPP_USING_IF_EXISTS; + using ::hypotl _LIBCPP_USING_IF_EXISTS; // [c.math.hypot3], three-dimensional hypotenuse - using ::pow; - using ::powf; - using ::powl; + using ::pow _LIBCPP_USING_IF_EXISTS; + using ::powf _LIBCPP_USING_IF_EXISTS; + using ::powl _LIBCPP_USING_IF_EXISTS; - using ::sqrt; - using ::sqrtf; - using ::sqrtl; + using ::sqrt _LIBCPP_USING_IF_EXISTS; + using ::sqrtf _LIBCPP_USING_IF_EXISTS; + using ::sqrtl _LIBCPP_USING_IF_EXISTS; - using ::erf; - using ::erff; - using ::erfl; + using ::erf _LIBCPP_USING_IF_EXISTS; + using ::erff _LIBCPP_USING_IF_EXISTS; + using ::erfl _LIBCPP_USING_IF_EXISTS; - using ::erfc; - using ::erfcf; - using ::erfcl; + using ::erfc _LIBCPP_USING_IF_EXISTS; + using ::erfcf _LIBCPP_USING_IF_EXISTS; + using ::erfcl _LIBCPP_USING_IF_EXISTS; - using ::lgamma; - using ::lgammaf; - using ::lgammal; + using ::lgamma _LIBCPP_USING_IF_EXISTS; + using ::lgammaf _LIBCPP_USING_IF_EXISTS; + using ::lgammal _LIBCPP_USING_IF_EXISTS; - using ::tgamma; - using ::tgammaf; - using ::tgammal; + using ::tgamma _LIBCPP_USING_IF_EXISTS; + using ::tgammaf _LIBCPP_USING_IF_EXISTS; + using ::tgammal _LIBCPP_USING_IF_EXISTS; - using ::ceil; - using ::ceilf; - using ::ceill; + using ::ceil _LIBCPP_USING_IF_EXISTS; + using ::ceilf _LIBCPP_USING_IF_EXISTS; + using ::ceill _LIBCPP_USING_IF_EXISTS; - using ::floor; - using ::floorf; - using ::floorl; + using ::floor _LIBCPP_USING_IF_EXISTS; + using ::floorf _LIBCPP_USING_IF_EXISTS; + using ::floorl _LIBCPP_USING_IF_EXISTS; - using ::nearbyint; - using ::nearbyintf; - using ::nearbyintl; + using ::nearbyint _LIBCPP_USING_IF_EXISTS; + using ::nearbyintf _LIBCPP_USING_IF_EXISTS; + using ::nearbyintl _LIBCPP_USING_IF_EXISTS; - using ::rint; - using ::rintf; - using ::rintl; + using ::rint _LIBCPP_USING_IF_EXISTS; + using ::rintf _LIBCPP_USING_IF_EXISTS; + using ::rintl _LIBCPP_USING_IF_EXISTS; - using ::lrint; - using ::lrintf; - using ::lrintl; + using ::lrint _LIBCPP_USING_IF_EXISTS; + using ::lrintf _LIBCPP_USING_IF_EXISTS; + using ::lrintl _LIBCPP_USING_IF_EXISTS; - using ::llrint; - using ::llrintf; - using ::llrintl; + using ::llrint _LIBCPP_USING_IF_EXISTS; + using ::llrintf _LIBCPP_USING_IF_EXISTS; + using ::llrintl _LIBCPP_USING_IF_EXISTS; - using ::round; - using ::roundf; - using ::roundl; + using ::round _LIBCPP_USING_IF_EXISTS; + using ::roundf _LIBCPP_USING_IF_EXISTS; + using ::roundl _LIBCPP_USING_IF_EXISTS; - using ::lround; - using ::lroundf; - using ::lroundl; + using ::lround _LIBCPP_USING_IF_EXISTS; + using ::lroundf _LIBCPP_USING_IF_EXISTS; + using ::lroundl _LIBCPP_USING_IF_EXISTS; - using ::llround; - using ::llroundf; - using ::llroundl; + using ::llround _LIBCPP_USING_IF_EXISTS; + using ::llroundf _LIBCPP_USING_IF_EXISTS; + using ::llroundl _LIBCPP_USING_IF_EXISTS; - using ::trunc; - using ::truncf; - using ::truncl; + using ::trunc _LIBCPP_USING_IF_EXISTS; + using ::truncf _LIBCPP_USING_IF_EXISTS; + using ::truncl _LIBCPP_USING_IF_EXISTS; - using ::fmod; - using ::fmodf; - using ::fmodl; + using ::fmod _LIBCPP_USING_IF_EXISTS; + using ::fmodf _LIBCPP_USING_IF_EXISTS; + using ::fmodl _LIBCPP_USING_IF_EXISTS; - using ::remainder; - using ::remainderf; - using ::remainderl; + using ::remainder _LIBCPP_USING_IF_EXISTS; + using ::remainderf _LIBCPP_USING_IF_EXISTS; + using ::remainderl _LIBCPP_USING_IF_EXISTS; - using ::remquo; - using ::remquof; - using ::remquol; + using ::remquo _LIBCPP_USING_IF_EXISTS; + using ::remquof _LIBCPP_USING_IF_EXISTS; + using ::remquol _LIBCPP_USING_IF_EXISTS; - using ::copysign; - using ::copysignf; - using ::copysignl; + using ::copysign _LIBCPP_USING_IF_EXISTS; + using ::copysignf _LIBCPP_USING_IF_EXISTS; + using ::copysignl _LIBCPP_USING_IF_EXISTS; - using ::nan; - using ::nanf; - using ::nanl; + using ::nan _LIBCPP_USING_IF_EXISTS; + using ::nanf _LIBCPP_USING_IF_EXISTS; + using ::nanl _LIBCPP_USING_IF_EXISTS; - using ::nextafter; - using ::nextafterf; - using ::nextafterl; + using ::nextafter _LIBCPP_USING_IF_EXISTS; + using ::nextafterf _LIBCPP_USING_IF_EXISTS; + using ::nextafterl _LIBCPP_USING_IF_EXISTS; - using ::nexttoward; - using ::nexttowardf; - using ::nexttowardl; + using ::nexttoward _LIBCPP_USING_IF_EXISTS; + using ::nexttowardf _LIBCPP_USING_IF_EXISTS; + using ::nexttowardl _LIBCPP_USING_IF_EXISTS; - using ::fdim; - using ::fdimf; - using ::fdiml; + using ::fdim _LIBCPP_USING_IF_EXISTS; + using ::fdimf _LIBCPP_USING_IF_EXISTS; + using ::fdiml _LIBCPP_USING_IF_EXISTS; - using ::fmax; - using ::fmaxf; - using ::fmaxl; + using ::fmax _LIBCPP_USING_IF_EXISTS; + using ::fmaxf _LIBCPP_USING_IF_EXISTS; + using ::fmaxl _LIBCPP_USING_IF_EXISTS; - using ::fmin; - using ::fminf; - using ::fminl; + using ::fmin _LIBCPP_USING_IF_EXISTS; + using ::fminf _LIBCPP_USING_IF_EXISTS; + using ::fminl _LIBCPP_USING_IF_EXISTS; - using ::fma; - using ::fmaf; - using ::fmal; + using ::fma _LIBCPP_USING_IF_EXISTS; + using ::fmaf _LIBCPP_USING_IF_EXISTS; + using ::fmal _LIBCPP_USING_IF_EXISTS; // [c.math.lerp], linear interpolation // [support.c.headers.other]/1 @@ -251,18 +251,18 @@ export { // ... // [c.math.fpclass], classification / comparison functions - using ::fpclassify; - using ::isfinite; - using ::isgreater; - using ::isgreaterequal; - using ::isinf; - using ::isless; - using ::islessequal; - using ::islessgreater; - using ::isnan; - using ::isnormal; - using ::isunordered; - using ::signbit; + using ::fpclassify _LIBCPP_USING_IF_EXISTS; + using ::isfinite _LIBCPP_USING_IF_EXISTS; + using ::isgreater _LIBCPP_USING_IF_EXISTS; + using ::isgreaterequal _LIBCPP_USING_IF_EXISTS; + using ::isinf _LIBCPP_USING_IF_EXISTS; + using ::isless _LIBCPP_USING_IF_EXISTS; + using ::islessequal _LIBCPP_USING_IF_EXISTS; + using ::islessgreater _LIBCPP_USING_IF_EXISTS; + using ::isnan _LIBCPP_USING_IF_EXISTS; + using ::isnormal _LIBCPP_USING_IF_EXISTS; + using ::isunordered _LIBCPP_USING_IF_EXISTS; + using ::signbit _LIBCPP_USING_IF_EXISTS; // [sf.cmath], mathematical special functions } // export diff --git a/libcxx/modules/std.compat/csetjmp.inc b/libcxx/modules/std.compat/csetjmp.inc index 1fc42ea3ee0378..53e1421a2fbdd0 100644 --- a/libcxx/modules/std.compat/csetjmp.inc +++ b/libcxx/modules/std.compat/csetjmp.inc @@ -8,6 +8,6 @@ //===----------------------------------------------------------------------===// export { - using ::jmp_buf; - using ::longjmp; + using ::jmp_buf _LIBCPP_USING_IF_EXISTS; + using ::longjmp _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/csignal.inc b/libcxx/modules/std.compat/csignal.inc index 33af6a9f2b7343..bf72459df16535 100644 --- a/libcxx/modules/std.compat/csignal.inc +++ b/libcxx/modules/std.compat/csignal.inc @@ -8,10 +8,10 @@ //===----------------------------------------------------------------------===// export { - using ::sig_atomic_t; + using ::sig_atomic_t _LIBCPP_USING_IF_EXISTS; // [support.signal], signal handlers - using ::signal; + using ::signal _LIBCPP_USING_IF_EXISTS; - using ::raise; + using ::raise _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cstdarg.inc b/libcxx/modules/std.compat/cstdarg.inc index 3efb34617a8bff..79b5df4ec99ced 100644 --- a/libcxx/modules/std.compat/cstdarg.inc +++ b/libcxx/modules/std.compat/cstdarg.inc @@ -7,4 +7,4 @@ // //===----------------------------------------------------------------------===// -export { using ::va_list; } // export +export { using ::va_list _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cstddef.inc b/libcxx/modules/std.compat/cstddef.inc index 94ad036fd8f4a5..8704a31e01f326 100644 --- a/libcxx/modules/std.compat/cstddef.inc +++ b/libcxx/modules/std.compat/cstddef.inc @@ -8,10 +8,10 @@ //===----------------------------------------------------------------------===// export { - using ::max_align_t; + using ::max_align_t _LIBCPP_USING_IF_EXISTS; using ::nullptr_t; - using ::ptrdiff_t; - using ::size_t; + using ::ptrdiff_t _LIBCPP_USING_IF_EXISTS; + using ::size_t _LIBCPP_USING_IF_EXISTS; // [support.c.headers]/1 // ... placed within the global namespace scope, except for ... the diff --git a/libcxx/modules/std.compat/cstdint.inc b/libcxx/modules/std.compat/cstdint.inc index 1a74efc70ceaa1..a8dd6898cb266f 100644 --- a/libcxx/modules/std.compat/cstdint.inc +++ b/libcxx/modules/std.compat/cstdint.inc @@ -14,17 +14,17 @@ export { using ::int32_t _LIBCPP_USING_IF_EXISTS; using ::int64_t _LIBCPP_USING_IF_EXISTS; - using ::int_fast16_t; - using ::int_fast32_t; - using ::int_fast64_t; - using ::int_fast8_t; + using ::int_fast16_t _LIBCPP_USING_IF_EXISTS; + using ::int_fast32_t _LIBCPP_USING_IF_EXISTS; + using ::int_fast64_t _LIBCPP_USING_IF_EXISTS; + using ::int_fast8_t _LIBCPP_USING_IF_EXISTS; - using ::int_least16_t; - using ::int_least32_t; - using ::int_least64_t; - using ::int_least8_t; + using ::int_least16_t _LIBCPP_USING_IF_EXISTS; + using ::int_least32_t _LIBCPP_USING_IF_EXISTS; + using ::int_least64_t _LIBCPP_USING_IF_EXISTS; + using ::int_least8_t _LIBCPP_USING_IF_EXISTS; - using ::intmax_t; + using ::intmax_t _LIBCPP_USING_IF_EXISTS; using ::intptr_t _LIBCPP_USING_IF_EXISTS; @@ -34,17 +34,17 @@ export { using ::uint32_t _LIBCPP_USING_IF_EXISTS; using ::uint64_t _LIBCPP_USING_IF_EXISTS; - using ::uint_fast16_t; - using ::uint_fast32_t; - using ::uint_fast64_t; - using ::uint_fast8_t; + using ::uint_fast16_t _LIBCPP_USING_IF_EXISTS; + using ::uint_fast32_t _LIBCPP_USING_IF_EXISTS; + using ::uint_fast64_t _LIBCPP_USING_IF_EXISTS; + using ::uint_fast8_t _LIBCPP_USING_IF_EXISTS; - using ::uint_least16_t; - using ::uint_least32_t; - using ::uint_least64_t; - using ::uint_least8_t; + using ::uint_least16_t _LIBCPP_USING_IF_EXISTS; + using ::uint_least32_t _LIBCPP_USING_IF_EXISTS; + using ::uint_least64_t _LIBCPP_USING_IF_EXISTS; + using ::uint_least8_t _LIBCPP_USING_IF_EXISTS; - using ::uintmax_t; + using ::uintmax_t _LIBCPP_USING_IF_EXISTS; using ::uintptr_t _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cstdio.inc b/libcxx/modules/std.compat/cstdio.inc index 1ec3015c9e2a2e..33dd2cbfb0d7c3 100644 --- a/libcxx/modules/std.compat/cstdio.inc +++ b/libcxx/modules/std.compat/cstdio.inc @@ -8,54 +8,54 @@ //===----------------------------------------------------------------------===// export { - using ::FILE; - using ::fpos_t; - using ::size_t; + using ::FILE _LIBCPP_USING_IF_EXISTS; + using ::fpos_t _LIBCPP_USING_IF_EXISTS; + using ::size_t _LIBCPP_USING_IF_EXISTS; - using ::clearerr; - using ::fclose; - using ::feof; - using ::ferror; - using ::fflush; - using ::fgetc; - using ::fgetpos; - using ::fgets; - using ::fopen; - using ::fprintf; - using ::fputc; - using ::fputs; - using ::fread; - using ::freopen; - using ::fscanf; - using ::fseek; - using ::fsetpos; - using ::ftell; - using ::fwrite; - using ::getc; - using ::getchar; - using ::perror; - using ::printf; - using ::putc; - using ::putchar; - using ::puts; - using ::remove; - using ::rename; - using ::rewind; - using ::scanf; - using ::setbuf; - using ::setvbuf; - using ::snprintf; - using ::sprintf; - using ::sscanf; - using ::tmpfile; - using ::tmpnam; - using ::ungetc; - using ::vfprintf; - using ::vfscanf; - using ::vprintf; - using ::vscanf; - using ::vsnprintf; - using ::vsprintf; - using ::vsscanf; + using ::clearerr _LIBCPP_USING_IF_EXISTS; + using ::fclose _LIBCPP_USING_IF_EXISTS; + using ::feof _LIBCPP_USING_IF_EXISTS; + using ::ferror _LIBCPP_USING_IF_EXISTS; + using ::fflush _LIBCPP_USING_IF_EXISTS; + using ::fgetc _LIBCPP_USING_IF_EXISTS; + using ::fgetpos _LIBCPP_USING_IF_EXISTS; + using ::fgets _LIBCPP_USING_IF_EXISTS; + using ::fopen _LIBCPP_USING_IF_EXISTS; + using ::fprintf _LIBCPP_USING_IF_EXISTS; + using ::fputc _LIBCPP_USING_IF_EXISTS; + using ::fputs _LIBCPP_USING_IF_EXISTS; + using ::fread _LIBCPP_USING_IF_EXISTS; + using ::freopen _LIBCPP_USING_IF_EXISTS; + using ::fscanf _LIBCPP_USING_IF_EXISTS; + using ::fseek _LIBCPP_USING_IF_EXISTS; + using ::fsetpos _LIBCPP_USING_IF_EXISTS; + using ::ftell _LIBCPP_USING_IF_EXISTS; + using ::fwrite _LIBCPP_USING_IF_EXISTS; + using ::getc _LIBCPP_USING_IF_EXISTS; + using ::getchar _LIBCPP_USING_IF_EXISTS; + using ::perror _LIBCPP_USING_IF_EXISTS; + using ::printf _LIBCPP_USING_IF_EXISTS; + using ::putc _LIBCPP_USING_IF_EXISTS; + using ::putchar _LIBCPP_USING_IF_EXISTS; + using ::puts _LIBCPP_USING_IF_EXISTS; + using ::remove _LIBCPP_USING_IF_EXISTS; + using ::rename _LIBCPP_USING_IF_EXISTS; + using ::rewind _LIBCPP_USING_IF_EXISTS; + using ::scanf _LIBCPP_USING_IF_EXISTS; + using ::setbuf _LIBCPP_USING_IF_EXISTS; + using ::setvbuf _LIBCPP_USING_IF_EXISTS; + using ::snprintf _LIBCPP_USING_IF_EXISTS; + using ::sprintf _LIBCPP_USING_IF_EXISTS; + using ::sscanf _LIBCPP_USING_IF_EXISTS; + using ::tmpfile _LIBCPP_USING_IF_EXISTS; + using ::tmpnam _LIBCPP_USING_IF_EXISTS; + using ::ungetc _LIBCPP_USING_IF_EXISTS; + using ::vfprintf _LIBCPP_USING_IF_EXISTS; + using ::vfscanf _LIBCPP_USING_IF_EXISTS; + using ::vprintf _LIBCPP_USING_IF_EXISTS; + using ::vscanf _LIBCPP_USING_IF_EXISTS; + using ::vsnprintf _LIBCPP_USING_IF_EXISTS; + using ::vsprintf _LIBCPP_USING_IF_EXISTS; + using ::vsscanf _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cstdlib.inc b/libcxx/modules/std.compat/cstdlib.inc index 4783cbf5162390..94f5e7e8d7f451 100644 --- a/libcxx/modules/std.compat/cstdlib.inc +++ b/libcxx/modules/std.compat/cstdlib.inc @@ -8,65 +8,65 @@ //===----------------------------------------------------------------------===// export { - using ::div_t; - using ::ldiv_t; - using ::lldiv_t; - using ::size_t; + using ::div_t _LIBCPP_USING_IF_EXISTS; + using ::ldiv_t _LIBCPP_USING_IF_EXISTS; + using ::lldiv_t _LIBCPP_USING_IF_EXISTS; + using ::size_t _LIBCPP_USING_IF_EXISTS; // [support.start.term], start and termination - using ::_Exit; - using ::abort; + using ::_Exit _LIBCPP_USING_IF_EXISTS; + using ::abort _LIBCPP_USING_IF_EXISTS; using ::at_quick_exit _LIBCPP_USING_IF_EXISTS; - using ::atexit; - using ::exit; + using ::atexit _LIBCPP_USING_IF_EXISTS; + using ::exit _LIBCPP_USING_IF_EXISTS; using ::quick_exit _LIBCPP_USING_IF_EXISTS; - using ::getenv; - using ::system; + using ::getenv _LIBCPP_USING_IF_EXISTS; + using ::system _LIBCPP_USING_IF_EXISTS; // [c.malloc], C library memory allocation using ::aligned_alloc _LIBCPP_USING_IF_EXISTS; - using ::calloc; - using ::free; - using ::malloc; - using ::realloc; + using ::calloc _LIBCPP_USING_IF_EXISTS; + using ::free _LIBCPP_USING_IF_EXISTS; + using ::malloc _LIBCPP_USING_IF_EXISTS; + using ::realloc _LIBCPP_USING_IF_EXISTS; - using ::atof; - using ::atoi; - using ::atol; - using ::atoll; - using ::strtod; - using ::strtof; - using ::strtol; - using ::strtold; - using ::strtoll; - using ::strtoul; - using ::strtoull; + using ::atof _LIBCPP_USING_IF_EXISTS; + using ::atoi _LIBCPP_USING_IF_EXISTS; + using ::atol _LIBCPP_USING_IF_EXISTS; + using ::atoll _LIBCPP_USING_IF_EXISTS; + using ::strtod _LIBCPP_USING_IF_EXISTS; + using ::strtof _LIBCPP_USING_IF_EXISTS; + using ::strtol _LIBCPP_USING_IF_EXISTS; + using ::strtold _LIBCPP_USING_IF_EXISTS; + using ::strtoll _LIBCPP_USING_IF_EXISTS; + using ::strtoul _LIBCPP_USING_IF_EXISTS; + using ::strtoull _LIBCPP_USING_IF_EXISTS; // [c.mb.wcs], multibyte / wide string and character conversion functions - using ::mblen; + using ::mblen _LIBCPP_USING_IF_EXISTS; #ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS - using ::mbstowcs; - using ::mbtowc; - using ::wcstombs; - using ::wctomb; + using ::mbstowcs _LIBCPP_USING_IF_EXISTS; + using ::mbtowc _LIBCPP_USING_IF_EXISTS; + using ::wcstombs _LIBCPP_USING_IF_EXISTS; + using ::wctomb _LIBCPP_USING_IF_EXISTS; #endif // [alg.c.library], C standard library algorithms - using ::bsearch; - using ::qsort; + using ::bsearch _LIBCPP_USING_IF_EXISTS; + using ::qsort _LIBCPP_USING_IF_EXISTS; // [c.math.rand], low-quality random number generation - using ::rand; - using ::srand; + using ::rand _LIBCPP_USING_IF_EXISTS; + using ::srand _LIBCPP_USING_IF_EXISTS; // [c.math.abs], absolute values - using ::abs; + using ::abs _LIBCPP_USING_IF_EXISTS; - using ::labs; - using ::llabs; + using ::labs _LIBCPP_USING_IF_EXISTS; + using ::llabs _LIBCPP_USING_IF_EXISTS; - using ::div; - using ::ldiv; - using ::lldiv; + using ::div _LIBCPP_USING_IF_EXISTS; + using ::ldiv _LIBCPP_USING_IF_EXISTS; + using ::lldiv _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cstring.inc b/libcxx/modules/std.compat/cstring.inc index 090350ae814786..5029a7674bb210 100644 --- a/libcxx/modules/std.compat/cstring.inc +++ b/libcxx/modules/std.compat/cstring.inc @@ -8,29 +8,29 @@ //===----------------------------------------------------------------------===// export { - using ::size_t; + using ::size_t _LIBCPP_USING_IF_EXISTS; - using ::memchr; - using ::memcmp; - using ::memcpy; - using ::memmove; - using ::memset; - using ::strcat; - using ::strchr; - using ::strcmp; - using ::strcoll; - using ::strcpy; - using ::strcspn; - using ::strerror; - using ::strlen; - using ::strncat; - using ::strncmp; - using ::strncpy; - using ::strpbrk; - using ::strrchr; - using ::strspn; - using ::strstr; - using ::strtok; - using ::strxfrm; + using ::memchr _LIBCPP_USING_IF_EXISTS; + using ::memcmp _LIBCPP_USING_IF_EXISTS; + using ::memcpy _LIBCPP_USING_IF_EXISTS; + using ::memmove _LIBCPP_USING_IF_EXISTS; + using ::memset _LIBCPP_USING_IF_EXISTS; + using ::strcat _LIBCPP_USING_IF_EXISTS; + using ::strchr _LIBCPP_USING_IF_EXISTS; + using ::strcmp _LIBCPP_USING_IF_EXISTS; + using ::strcoll _LIBCPP_USING_IF_EXISTS; + using ::strcpy _LIBCPP_USING_IF_EXISTS; + using ::strcspn _LIBCPP_USING_IF_EXISTS; + using ::strerror _LIBCPP_USING_IF_EXISTS; + using ::strlen _LIBCPP_USING_IF_EXISTS; + using ::strncat _LIBCPP_USING_IF_EXISTS; + using ::strncmp _LIBCPP_USING_IF_EXISTS; + using ::strncpy _LIBCPP_USING_IF_EXISTS; + using ::strpbrk _LIBCPP_USING_IF_EXISTS; + using ::strrchr _LIBCPP_USING_IF_EXISTS; + using ::strspn _LIBCPP_USING_IF_EXISTS; + using ::strstr _LIBCPP_USING_IF_EXISTS; + using ::strtok _LIBCPP_USING_IF_EXISTS; + using ::strxfrm _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/ctime.inc b/libcxx/modules/std.compat/ctime.inc index 6e621f494348d7..eba8234a08969e 100644 --- a/libcxx/modules/std.compat/ctime.inc +++ b/libcxx/modules/std.compat/ctime.inc @@ -8,21 +8,21 @@ //===----------------------------------------------------------------------===// export { - using ::clock_t; - using ::size_t; - using ::time_t; + using ::clock_t _LIBCPP_USING_IF_EXISTS; + using ::size_t _LIBCPP_USING_IF_EXISTS; + using ::time_t _LIBCPP_USING_IF_EXISTS; - using ::timespec; - using ::tm; + using ::timespec _LIBCPP_USING_IF_EXISTS; + using ::tm _LIBCPP_USING_IF_EXISTS; - using ::asctime; - using ::clock; - using ::ctime; - using ::difftime; - using ::gmtime; - using ::localtime; - using ::mktime; - using ::strftime; - using ::time; + using ::asctime _LIBCPP_USING_IF_EXISTS; + using ::clock _LIBCPP_USING_IF_EXISTS; + using ::ctime _LIBCPP_USING_IF_EXISTS; + using ::difftime _LIBCPP_USING_IF_EXISTS; + using ::gmtime _LIBCPP_USING_IF_EXISTS; + using ::localtime _LIBCPP_USING_IF_EXISTS; + using ::mktime _LIBCPP_USING_IF_EXISTS; + using ::strftime _LIBCPP_USING_IF_EXISTS; + using ::time _LIBCPP_USING_IF_EXISTS; using ::timespec_get _LIBCPP_USING_IF_EXISTS; } // export diff --git a/libcxx/modules/std.compat/cwchar.inc b/libcxx/modules/std.compat/cwchar.inc index 8905aecbdfecc2..4cad9281fb49a2 100644 --- a/libcxx/modules/std.compat/cwchar.inc +++ b/libcxx/modules/std.compat/cwchar.inc @@ -9,72 +9,72 @@ export { #ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS - using ::mbstate_t; - using ::size_t; - using ::wint_t; + using ::mbstate_t _LIBCPP_USING_IF_EXISTS; + using ::size_t _LIBCPP_USING_IF_EXISTS; + using ::wint_t _LIBCPP_USING_IF_EXISTS; - using ::tm; + using ::tm _LIBCPP_USING_IF_EXISTS; - using ::btowc; - using ::fgetwc; - using ::fgetws; - using ::fputwc; - using ::fputws; - using ::fwide; - using ::fwprintf; - using ::fwscanf; - using ::getwc; - using ::getwchar; - using ::putwc; - using ::putwchar; - using ::swprintf; - using ::swscanf; - using ::ungetwc; - using ::vfwprintf; - using ::vfwscanf; - using ::vswprintf; - using ::vswscanf; - using ::vwprintf; - using ::vwscanf; - using ::wcscat; - using ::wcschr; - using ::wcscmp; - using ::wcscoll; - using ::wcscpy; - using ::wcscspn; - using ::wcsftime; - using ::wcslen; - using ::wcsncat; - using ::wcsncmp; - using ::wcsncpy; - using ::wcspbrk; - using ::wcsrchr; - using ::wcsspn; - using ::wcsstr; - using ::wcstod; - using ::wcstof; - using ::wcstok; - using ::wcstol; - using ::wcstold; - using ::wcstoll; - using ::wcstoul; - using ::wcstoull; - using ::wcsxfrm; - using ::wctob; - using ::wmemchr; - using ::wmemcmp; - using ::wmemcpy; - using ::wmemmove; - using ::wmemset; - using ::wprintf; - using ::wscanf; + using ::btowc _LIBCPP_USING_IF_EXISTS; + using ::fgetwc _LIBCPP_USING_IF_EXISTS; + using ::fgetws _LIBCPP_USING_IF_EXISTS; + using ::fputwc _LIBCPP_USING_IF_EXISTS; + using ::fputws _LIBCPP_USING_IF_EXISTS; + using ::fwide _LIBCPP_USING_IF_EXISTS; + using ::fwprintf _LIBCPP_USING_IF_EXISTS; + using ::fwscanf _LIBCPP_USING_IF_EXISTS; + using ::getwc _LIBCPP_USING_IF_EXISTS; + using ::getwchar _LIBCPP_USING_IF_EXISTS; + using ::putwc _LIBCPP_USING_IF_EXISTS; + using ::putwchar _LIBCPP_USING_IF_EXISTS; + using ::swprintf _LIBCPP_USING_IF_EXISTS; + using ::swscanf _LIBCPP_USING_IF_EXISTS; + using ::ungetwc _LIBCPP_USING_IF_EXISTS; + using ::vfwprintf _LIBCPP_USING_IF_EXISTS; + using ::vfwscanf _LIBCPP_USING_IF_EXISTS; + using ::vswprintf _LIBCPP_USING_IF_EXISTS; + using ::vswscanf _LIBCPP_USING_IF_EXISTS; + using ::vwprintf _LIBCPP_USING_IF_EXISTS; + using ::vwscanf _LIBCPP_USING_IF_EXISTS; + using ::wcscat _LIBCPP_USING_IF_EXISTS; + using ::wcschr _LIBCPP_USING_IF_EXISTS; + using ::wcscmp _LIBCPP_USING_IF_EXISTS; + using ::wcscoll _LIBCPP_USING_IF_EXISTS; + using ::wcscpy _LIBCPP_USING_IF_EXISTS; + using ::wcscspn _LIBCPP_USING_IF_EXISTS; + using ::wcsftime _LIBCPP_USING_IF_EXISTS; + using ::wcslen _LIBCPP_USING_IF_EXISTS; + using ::wcsncat _LIBCPP_USING_IF_EXISTS; + using ::wcsncmp _LIBCPP_USING_IF_EXISTS; + using ::wcsncpy _LIBCPP_USING_IF_EXISTS; + using ::wcspbrk _LIBCPP_USING_IF_EXISTS; + using ::wcsrchr _LIBCPP_USING_IF_EXISTS; + using ::wcsspn _LIBCPP_USING_IF_EXISTS; + using ::wcsstr _LIBCPP_USING_IF_EXISTS; + using ::wcstod _LIBCPP_USING_IF_EXISTS; + using ::wcstof _LIBCPP_USING_IF_EXISTS; + using ::wcstok _LIBCPP_USING_IF_EXISTS; + using ::wcstol _LIBCPP_USING_IF_EXISTS; + using ::wcstold _LIBCPP_USING_IF_EXISTS; + using ::wcstoll _LIBCPP_USING_IF_EXISTS; + using ::wcstoul _LIBCPP_USING_IF_EXISTS; + using ::wcstoull _LIBCPP_USING_IF_EXISTS; + using ::wcsxfrm _LIBCPP_USING_IF_EXISTS; + using ::wctob _LIBCPP_USING_IF_EXISTS; + using ::wmemchr _LIBCPP_USING_IF_EXISTS; + using ::wmemcmp _LIBCPP_USING_IF_EXISTS; + using ::wmemcpy _LIBCPP_USING_IF_EXISTS; + using ::wmemmove _LIBCPP_USING_IF_EXISTS; + using ::wmemset _LIBCPP_USING_IF_EXISTS; + using ::wprintf _LIBCPP_USING_IF_EXISTS; + using ::wscanf _LIBCPP_USING_IF_EXISTS; // [c.mb.wcs], multibyte / wide string and character conversion functions - using ::mbrlen; - using ::mbrtowc; - using ::mbsinit; - using ::mbsrtowcs; - using ::wcrtomb; - using ::wcsrtombs; + using ::mbrlen _LIBCPP_USING_IF_EXISTS; + using ::mbrtowc _LIBCPP_USING_IF_EXISTS; + using ::mbsinit _LIBCPP_USING_IF_EXISTS; + using ::mbsrtowcs _LIBCPP_USING_IF_EXISTS; + using ::wcrtomb _LIBCPP_USING_IF_EXISTS; + using ::wcsrtombs _LIBCPP_USING_IF_EXISTS; #endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS } // export diff --git a/libcxx/modules/std.compat/cwctype.inc b/libcxx/modules/std.compat/cwctype.inc index 13aa2b7f3fb746..8d06eaa379eaa2 100644 --- a/libcxx/modules/std.compat/cwctype.inc +++ b/libcxx/modules/std.compat/cwctype.inc @@ -9,27 +9,27 @@ export { #ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS - using ::wctrans_t; - using ::wctype_t; - using ::wint_t; + using ::wctrans_t _LIBCPP_USING_IF_EXISTS; + using ::wctype_t _LIBCPP_USING_IF_EXISTS; + using ::wint_t _LIBCPP_USING_IF_EXISTS; - using ::iswalnum; - using ::iswalpha; - using ::iswblank; - using ::iswcntrl; - using ::iswctype; - using ::iswdigit; - using ::iswgraph; - using ::iswlower; - using ::iswprint; - using ::iswpunct; - using ::iswspace; - using ::iswupper; - using ::iswxdigit; - using ::towctrans; - using ::towlower; - using ::towupper; - using ::wctrans; - using ::wctype; + using ::iswalnum _LIBCPP_USING_IF_EXISTS; + using ::iswalpha _LIBCPP_USING_IF_EXISTS; + using ::iswblank _LIBCPP_USING_IF_EXISTS; + using ::iswcntrl _LIBCPP_USING_IF_EXISTS; + using ::iswctype _LIBCPP_USING_IF_EXISTS; + using ::iswdigit _LIBCPP_USING_IF_EXISTS; + using ::iswgraph _LIBCPP_USING_IF_EXISTS; + using ::iswlower _LIBCPP_USING_IF_EXISTS; + using ::iswprint _LIBCPP_USING_IF_EXISTS; + using ::iswpunct _LIBCPP_USING_IF_EXISTS; + using ::iswspace _LIBCPP_USING_IF_EXISTS; + using ::iswupper _LIBCPP_USING_IF_EXISTS; + using ::iswxdigit _LIBCPP_USING_IF_EXISTS; + using ::towctrans _LIBCPP_USING_IF_EXISTS; + using ::towlower _LIBCPP_USING_IF_EXISTS; + using ::towupper _LIBCPP_USING_IF_EXISTS; + using ::wctrans _LIBCPP_USING_IF_EXISTS; + using ::wctype _LIBCPP_USING_IF_EXISTS; #endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS } // export diff --git a/libcxx/modules/std/atomic.inc b/libcxx/modules/std/atomic.inc index 2b54cef863e571..d77d7a5bb0fbc1 100644 --- a/libcxx/modules/std/atomic.inc +++ b/libcxx/modules/std/atomic.inc @@ -10,132 +10,132 @@ export namespace std { // [atomics.order], order and consistency - using std::memory_order; - using std::memory_order_acq_rel; - using std::memory_order_acquire; - using std::memory_order_consume; - using std::memory_order_relaxed; - using std::memory_order_release; - using std::memory_order_seq_cst; + using std::memory_order _LIBCPP_USING_IF_EXISTS; + using std::memory_order_acq_rel _LIBCPP_USING_IF_EXISTS; + using std::memory_order_acquire _LIBCPP_USING_IF_EXISTS; + using std::memory_order_consume _LIBCPP_USING_IF_EXISTS; + using std::memory_order_relaxed _LIBCPP_USING_IF_EXISTS; + using std::memory_order_release _LIBCPP_USING_IF_EXISTS; + using std::memory_order_seq_cst _LIBCPP_USING_IF_EXISTS; - using std::kill_dependency; + using std::kill_dependency _LIBCPP_USING_IF_EXISTS; // [atomics.ref.generic], class template atomic_ref // [atomics.ref.pointer], partial specialization for pointers - // using std::atomic_ref; + // using std::atomic_ref _LIBCPP_USING_IF_EXISTS; // [atomics.types.generic], class template atomic - using std::atomic; + using std::atomic _LIBCPP_USING_IF_EXISTS; // [atomics.nonmembers], non-member functions - using std::atomic_compare_exchange_strong; - using std::atomic_compare_exchange_strong_explicit; - using std::atomic_compare_exchange_weak; - using std::atomic_compare_exchange_weak_explicit; - using std::atomic_exchange; - using std::atomic_exchange_explicit; - using std::atomic_is_lock_free; - using std::atomic_load; - using std::atomic_load_explicit; - using std::atomic_store; - using std::atomic_store_explicit; - - using std::atomic_fetch_add; - using std::atomic_fetch_add_explicit; - using std::atomic_fetch_and; - using std::atomic_fetch_and_explicit; - using std::atomic_fetch_or; - using std::atomic_fetch_or_explicit; - using std::atomic_fetch_sub; - using std::atomic_fetch_sub_explicit; - using std::atomic_fetch_xor; - using std::atomic_fetch_xor_explicit; - using std::atomic_notify_all; - using std::atomic_notify_one; - using std::atomic_wait; - using std::atomic_wait_explicit; + using std::atomic_compare_exchange_strong _LIBCPP_USING_IF_EXISTS; + using std::atomic_compare_exchange_strong_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_compare_exchange_weak _LIBCPP_USING_IF_EXISTS; + using std::atomic_compare_exchange_weak_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_exchange _LIBCPP_USING_IF_EXISTS; + using std::atomic_exchange_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_is_lock_free _LIBCPP_USING_IF_EXISTS; + using std::atomic_load _LIBCPP_USING_IF_EXISTS; + using std::atomic_load_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_store _LIBCPP_USING_IF_EXISTS; + using std::atomic_store_explicit _LIBCPP_USING_IF_EXISTS; + + using std::atomic_fetch_add _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_add_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_and _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_and_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_or _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_or_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_sub _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_sub_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_xor _LIBCPP_USING_IF_EXISTS; + using std::atomic_fetch_xor_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_notify_all _LIBCPP_USING_IF_EXISTS; + using std::atomic_notify_one _LIBCPP_USING_IF_EXISTS; + using std::atomic_wait _LIBCPP_USING_IF_EXISTS; + using std::atomic_wait_explicit _LIBCPP_USING_IF_EXISTS; // [atomics.alias], type aliases - using std::atomic_bool; - using std::atomic_char; - using std::atomic_char16_t; - using std::atomic_char32_t; + using std::atomic_bool _LIBCPP_USING_IF_EXISTS; + using std::atomic_char _LIBCPP_USING_IF_EXISTS; + using std::atomic_char16_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_char32_t _LIBCPP_USING_IF_EXISTS; #ifndef _LIBCPP_HAS_NO_CHAR8_T - using std::atomic_char8_t; + using std::atomic_char8_t _LIBCPP_USING_IF_EXISTS; #endif - using std::atomic_int; - using std::atomic_llong; - using std::atomic_long; - using std::atomic_schar; - using std::atomic_short; - using std::atomic_uchar; - using std::atomic_uint; - using std::atomic_ullong; - using std::atomic_ulong; - using std::atomic_ushort; + using std::atomic_int _LIBCPP_USING_IF_EXISTS; + using std::atomic_llong _LIBCPP_USING_IF_EXISTS; + using std::atomic_long _LIBCPP_USING_IF_EXISTS; + using std::atomic_schar _LIBCPP_USING_IF_EXISTS; + using std::atomic_short _LIBCPP_USING_IF_EXISTS; + using std::atomic_uchar _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint _LIBCPP_USING_IF_EXISTS; + using std::atomic_ullong _LIBCPP_USING_IF_EXISTS; + using std::atomic_ulong _LIBCPP_USING_IF_EXISTS; + using std::atomic_ushort _LIBCPP_USING_IF_EXISTS; #ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS - using std::atomic_wchar_t; + using std::atomic_wchar_t _LIBCPP_USING_IF_EXISTS; #endif - using std::atomic_int16_t; - using std::atomic_int32_t; - using std::atomic_int64_t; - using std::atomic_int8_t; - using std::atomic_uint16_t; - using std::atomic_uint32_t; - using std::atomic_uint64_t; - using std::atomic_uint8_t; - - using std::atomic_int_least16_t; - using std::atomic_int_least32_t; - using std::atomic_int_least64_t; - using std::atomic_int_least8_t; - using std::atomic_uint_least16_t; - using std::atomic_uint_least32_t; - using std::atomic_uint_least64_t; - using std::atomic_uint_least8_t; - - using std::atomic_int_fast16_t; - using std::atomic_int_fast32_t; - using std::atomic_int_fast64_t; - using std::atomic_int_fast8_t; - using std::atomic_uint_fast16_t; - using std::atomic_uint_fast32_t; - using std::atomic_uint_fast64_t; - using std::atomic_uint_fast8_t; - - using std::atomic_intmax_t; - using std::atomic_intptr_t; - using std::atomic_ptrdiff_t; - using std::atomic_size_t; - using std::atomic_uintmax_t; - using std::atomic_uintptr_t; + using std::atomic_int16_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int32_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int64_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int8_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint16_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint32_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint64_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint8_t _LIBCPP_USING_IF_EXISTS; + + using std::atomic_int_least16_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int_least32_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int_least64_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int_least8_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_least16_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_least32_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_least64_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_least8_t _LIBCPP_USING_IF_EXISTS; + + using std::atomic_int_fast16_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int_fast32_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int_fast64_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_int_fast8_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_fast16_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_fast32_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_fast64_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uint_fast8_t _LIBCPP_USING_IF_EXISTS; + + using std::atomic_intmax_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_intptr_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_ptrdiff_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_size_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uintmax_t _LIBCPP_USING_IF_EXISTS; + using std::atomic_uintptr_t _LIBCPP_USING_IF_EXISTS; #ifndef _LIBCPP_NO_LOCK_FREE_TYPES - using std::atomic_signed_lock_free; - using std::atomic_unsigned_lock_free; + using std::atomic_signed_lock_free _LIBCPP_USING_IF_EXISTS; + using std::atomic_unsigned_lock_free _LIBCPP_USING_IF_EXISTS; #endif // [atomics.flag], flag type and operations - using std::atomic_flag; + using std::atomic_flag _LIBCPP_USING_IF_EXISTS; - using std::atomic_flag_clear; - using std::atomic_flag_clear_explicit; - using std::atomic_flag_test; - using std::atomic_flag_test_and_set; - using std::atomic_flag_test_and_set_explicit; - using std::atomic_flag_test_explicit; + using std::atomic_flag_clear _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_clear_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_test _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_test_and_set _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_test_and_set_explicit _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_test_explicit _LIBCPP_USING_IF_EXISTS; - using std::atomic_flag_notify_all; - using std::atomic_flag_notify_one; - using std::atomic_flag_wait; - using std::atomic_flag_wait_explicit; + using std::atomic_flag_notify_all _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_notify_one _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_wait _LIBCPP_USING_IF_EXISTS; + using std::atomic_flag_wait_explicit _LIBCPP_USING_IF_EXISTS; // [atomics.fences], fences - using std::atomic_signal_fence; - using std::atomic_thread_fence; + using std::atomic_signal_fence _LIBCPP_USING_IF_EXISTS; + using std::atomic_thread_fence _LIBCPP_USING_IF_EXISTS; // [depr.atomics.nonmembers] - using std::atomic_init; + using std::atomic_init _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cctype.inc b/libcxx/modules/std/cctype.inc index 075dbbe78198e8..43417aa159624c 100644 --- a/libcxx/modules/std/cctype.inc +++ b/libcxx/modules/std/cctype.inc @@ -8,18 +8,18 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::isalnum; - using std::isalpha; - using std::isblank; - using std::iscntrl; - using std::isdigit; - using std::isgraph; - using std::islower; - using std::isprint; - using std::ispunct; - using std::isspace; - using std::isupper; - using std::isxdigit; - using std::tolower; - using std::toupper; + using std::isalnum _LIBCPP_USING_IF_EXISTS; + using std::isalpha _LIBCPP_USING_IF_EXISTS; + using std::isblank _LIBCPP_USING_IF_EXISTS; + using std::iscntrl _LIBCPP_USING_IF_EXISTS; + using std::isdigit _LIBCPP_USING_IF_EXISTS; + using std::isgraph _LIBCPP_USING_IF_EXISTS; + using std::islower _LIBCPP_USING_IF_EXISTS; + using std::isprint _LIBCPP_USING_IF_EXISTS; + using std::ispunct _LIBCPP_USING_IF_EXISTS; + using std::isspace _LIBCPP_USING_IF_EXISTS; + using std::isupper _LIBCPP_USING_IF_EXISTS; + using std::isxdigit _LIBCPP_USING_IF_EXISTS; + using std::tolower _LIBCPP_USING_IF_EXISTS; + using std::toupper _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cfenv.inc b/libcxx/modules/std/cfenv.inc index 34a8a7afa846f5..831c1fed8ebefb 100644 --- a/libcxx/modules/std/cfenv.inc +++ b/libcxx/modules/std/cfenv.inc @@ -9,22 +9,22 @@ export namespace std { // types - using std::fenv_t; - using std::fexcept_t; + using std::fenv_t _LIBCPP_USING_IF_EXISTS; + using std::fexcept_t _LIBCPP_USING_IF_EXISTS; // functions - using std::feclearexcept; - using std::fegetexceptflag; - using std::feraiseexcept; - using std::fesetexceptflag; - using std::fetestexcept; + using std::feclearexcept _LIBCPP_USING_IF_EXISTS; + using std::fegetexceptflag _LIBCPP_USING_IF_EXISTS; + using std::feraiseexcept _LIBCPP_USING_IF_EXISTS; + using std::fesetexceptflag _LIBCPP_USING_IF_EXISTS; + using std::fetestexcept _LIBCPP_USING_IF_EXISTS; - using std::fegetround; - using std::fesetround; + using std::fegetround _LIBCPP_USING_IF_EXISTS; + using std::fesetround _LIBCPP_USING_IF_EXISTS; - using std::fegetenv; - using std::feholdexcept; - using std::fesetenv; - using std::feupdateenv; + using std::fegetenv _LIBCPP_USING_IF_EXISTS; + using std::feholdexcept _LIBCPP_USING_IF_EXISTS; + using std::fesetenv _LIBCPP_USING_IF_EXISTS; + using std::feupdateenv _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cinttypes.inc b/libcxx/modules/std/cinttypes.inc index 2e135926598652..b2b98c973e9826 100644 --- a/libcxx/modules/std/cinttypes.inc +++ b/libcxx/modules/std/cinttypes.inc @@ -8,14 +8,14 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::imaxdiv_t; + using std::imaxdiv_t _LIBCPP_USING_IF_EXISTS; - using std::imaxabs; - using std::imaxdiv; - using std::strtoimax; - using std::strtoumax; - using std::wcstoimax; - using std::wcstoumax; + using std::imaxabs _LIBCPP_USING_IF_EXISTS; + using std::imaxdiv _LIBCPP_USING_IF_EXISTS; + using std::strtoimax _LIBCPP_USING_IF_EXISTS; + using std::strtoumax _LIBCPP_USING_IF_EXISTS; + using std::wcstoimax _LIBCPP_USING_IF_EXISTS; + using std::wcstoumax _LIBCPP_USING_IF_EXISTS; // abs is conditionally here, but always present in cmath.cppm. To avoid // conflicing declarations omit the using here. diff --git a/libcxx/modules/std/clocale.inc b/libcxx/modules/std/clocale.inc index 3efe1595dc05d6..359868a61eb9d7 100644 --- a/libcxx/modules/std/clocale.inc +++ b/libcxx/modules/std/clocale.inc @@ -9,9 +9,9 @@ export namespace std { #ifndef _LIBCPP_HAS_NO_LOCALIZATION - using std::lconv; + using std::lconv _LIBCPP_USING_IF_EXISTS; - using std::localeconv; - using std::setlocale; + using std::localeconv _LIBCPP_USING_IF_EXISTS; + using std::setlocale _LIBCPP_USING_IF_EXISTS; #endif // _LIBCPP_HAS_NO_LOCALIZATION } // namespace std diff --git a/libcxx/modules/std/cmath.inc b/libcxx/modules/std/cmath.inc index 0fe887447ad850..a463c1e3ccf861 100644 --- a/libcxx/modules/std/cmath.inc +++ b/libcxx/modules/std/cmath.inc @@ -9,258 +9,258 @@ export namespace std { - using std::double_t; - using std::float_t; + using std::double_t _LIBCPP_USING_IF_EXISTS; + using std::float_t _LIBCPP_USING_IF_EXISTS; - using std::acos; - using std::acosf; - using std::acosl; + using std::acos _LIBCPP_USING_IF_EXISTS; + using std::acosf _LIBCPP_USING_IF_EXISTS; + using std::acosl _LIBCPP_USING_IF_EXISTS; - using std::asin; - using std::asinf; - using std::asinl; + using std::asin _LIBCPP_USING_IF_EXISTS; + using std::asinf _LIBCPP_USING_IF_EXISTS; + using std::asinl _LIBCPP_USING_IF_EXISTS; - using std::atan; - using std::atanf; - using std::atanl; + using std::atan _LIBCPP_USING_IF_EXISTS; + using std::atanf _LIBCPP_USING_IF_EXISTS; + using std::atanl _LIBCPP_USING_IF_EXISTS; - using std::atan2; - using std::atan2f; - using std::atan2l; + using std::atan2 _LIBCPP_USING_IF_EXISTS; + using std::atan2f _LIBCPP_USING_IF_EXISTS; + using std::atan2l _LIBCPP_USING_IF_EXISTS; - using std::cos; - using std::cosf; - using std::cosl; + using std::cos _LIBCPP_USING_IF_EXISTS; + using std::cosf _LIBCPP_USING_IF_EXISTS; + using std::cosl _LIBCPP_USING_IF_EXISTS; - using std::sin; - using std::sinf; - using std::sinl; + using std::sin _LIBCPP_USING_IF_EXISTS; + using std::sinf _LIBCPP_USING_IF_EXISTS; + using std::sinl _LIBCPP_USING_IF_EXISTS; - using std::tan; - using std::tanf; - using std::tanl; + using std::tan _LIBCPP_USING_IF_EXISTS; + using std::tanf _LIBCPP_USING_IF_EXISTS; + using std::tanl _LIBCPP_USING_IF_EXISTS; - using std::acosh; - using std::acoshf; - using std::acoshl; + using std::acosh _LIBCPP_USING_IF_EXISTS; + using std::acoshf _LIBCPP_USING_IF_EXISTS; + using std::acoshl _LIBCPP_USING_IF_EXISTS; - using std::asinh; - using std::asinhf; - using std::asinhl; + using std::asinh _LIBCPP_USING_IF_EXISTS; + using std::asinhf _LIBCPP_USING_IF_EXISTS; + using std::asinhl _LIBCPP_USING_IF_EXISTS; - using std::atanh; - using std::atanhf; - using std::atanhl; + using std::atanh _LIBCPP_USING_IF_EXISTS; + using std::atanhf _LIBCPP_USING_IF_EXISTS; + using std::atanhl _LIBCPP_USING_IF_EXISTS; - using std::cosh; - using std::coshf; - using std::coshl; + using std::cosh _LIBCPP_USING_IF_EXISTS; + using std::coshf _LIBCPP_USING_IF_EXISTS; + using std::coshl _LIBCPP_USING_IF_EXISTS; - using std::sinh; - using std::sinhf; - using std::sinhl; + using std::sinh _LIBCPP_USING_IF_EXISTS; + using std::sinhf _LIBCPP_USING_IF_EXISTS; + using std::sinhl _LIBCPP_USING_IF_EXISTS; - using std::tanh; - using std::tanhf; - using std::tanhl; + using std::tanh _LIBCPP_USING_IF_EXISTS; + using std::tanhf _LIBCPP_USING_IF_EXISTS; + using std::tanhl _LIBCPP_USING_IF_EXISTS; - using std::exp; - using std::expf; - using std::expl; + using std::exp _LIBCPP_USING_IF_EXISTS; + using std::expf _LIBCPP_USING_IF_EXISTS; + using std::expl _LIBCPP_USING_IF_EXISTS; - using std::exp2; - using std::exp2f; - using std::exp2l; + using std::exp2 _LIBCPP_USING_IF_EXISTS; + using std::exp2f _LIBCPP_USING_IF_EXISTS; + using std::exp2l _LIBCPP_USING_IF_EXISTS; - using std::expm1; - using std::expm1f; - using std::expm1l; + using std::expm1 _LIBCPP_USING_IF_EXISTS; + using std::expm1f _LIBCPP_USING_IF_EXISTS; + using std::expm1l _LIBCPP_USING_IF_EXISTS; - using std::frexp; - using std::frexpf; - using std::frexpl; + using std::frexp _LIBCPP_USING_IF_EXISTS; + using std::frexpf _LIBCPP_USING_IF_EXISTS; + using std::frexpl _LIBCPP_USING_IF_EXISTS; - using std::ilogb; - using std::ilogbf; - using std::ilogbl; + using std::ilogb _LIBCPP_USING_IF_EXISTS; + using std::ilogbf _LIBCPP_USING_IF_EXISTS; + using std::ilogbl _LIBCPP_USING_IF_EXISTS; - using std::ldexp; - using std::ldexpf; - using std::ldexpl; + using std::ldexp _LIBCPP_USING_IF_EXISTS; + using std::ldexpf _LIBCPP_USING_IF_EXISTS; + using std::ldexpl _LIBCPP_USING_IF_EXISTS; - using std::log; - using std::logf; - using std::logl; + using std::log _LIBCPP_USING_IF_EXISTS; + using std::logf _LIBCPP_USING_IF_EXISTS; + using std::logl _LIBCPP_USING_IF_EXISTS; - using std::log10; - using std::log10f; - using std::log10l; + using std::log10 _LIBCPP_USING_IF_EXISTS; + using std::log10f _LIBCPP_USING_IF_EXISTS; + using std::log10l _LIBCPP_USING_IF_EXISTS; - using std::log1p; - using std::log1pf; - using std::log1pl; + using std::log1p _LIBCPP_USING_IF_EXISTS; + using std::log1pf _LIBCPP_USING_IF_EXISTS; + using std::log1pl _LIBCPP_USING_IF_EXISTS; - using std::log2; - using std::log2f; - using std::log2l; + using std::log2 _LIBCPP_USING_IF_EXISTS; + using std::log2f _LIBCPP_USING_IF_EXISTS; + using std::log2l _LIBCPP_USING_IF_EXISTS; - using std::logb; - using std::logbf; - using std::logbl; + using std::logb _LIBCPP_USING_IF_EXISTS; + using std::logbf _LIBCPP_USING_IF_EXISTS; + using std::logbl _LIBCPP_USING_IF_EXISTS; - using std::modf; - using std::modff; - using std::modfl; + using std::modf _LIBCPP_USING_IF_EXISTS; + using std::modff _LIBCPP_USING_IF_EXISTS; + using std::modfl _LIBCPP_USING_IF_EXISTS; - using std::scalbn; - using std::scalbnf; - using std::scalbnl; + using std::scalbn _LIBCPP_USING_IF_EXISTS; + using std::scalbnf _LIBCPP_USING_IF_EXISTS; + using std::scalbnl _LIBCPP_USING_IF_EXISTS; - using std::scalbln; - using std::scalblnf; - using std::scalblnl; + using std::scalbln _LIBCPP_USING_IF_EXISTS; + using std::scalblnf _LIBCPP_USING_IF_EXISTS; + using std::scalblnl _LIBCPP_USING_IF_EXISTS; - using std::cbrt; - using std::cbrtf; - using std::cbrtl; + using std::cbrt _LIBCPP_USING_IF_EXISTS; + using std::cbrtf _LIBCPP_USING_IF_EXISTS; + using std::cbrtl _LIBCPP_USING_IF_EXISTS; // [c.math.abs], absolute values - using std::abs; + using std::abs _LIBCPP_USING_IF_EXISTS; - using std::fabs; - using std::fabsf; - using std::fabsl; + using std::fabs _LIBCPP_USING_IF_EXISTS; + using std::fabsf _LIBCPP_USING_IF_EXISTS; + using std::fabsl _LIBCPP_USING_IF_EXISTS; - using std::hypot; - using std::hypotf; - using std::hypotl; + using std::hypot _LIBCPP_USING_IF_EXISTS; + using std::hypotf _LIBCPP_USING_IF_EXISTS; + using std::hypotl _LIBCPP_USING_IF_EXISTS; // [c.math.hypot3], three-dimensional hypotenuse - using std::pow; - using std::powf; - using std::powl; + using std::pow _LIBCPP_USING_IF_EXISTS; + using std::powf _LIBCPP_USING_IF_EXISTS; + using std::powl _LIBCPP_USING_IF_EXISTS; - using std::sqrt; - using std::sqrtf; - using std::sqrtl; + using std::sqrt _LIBCPP_USING_IF_EXISTS; + using std::sqrtf _LIBCPP_USING_IF_EXISTS; + using std::sqrtl _LIBCPP_USING_IF_EXISTS; - using std::erf; - using std::erff; - using std::erfl; + using std::erf _LIBCPP_USING_IF_EXISTS; + using std::erff _LIBCPP_USING_IF_EXISTS; + using std::erfl _LIBCPP_USING_IF_EXISTS; - using std::erfc; - using std::erfcf; - using std::erfcl; + using std::erfc _LIBCPP_USING_IF_EXISTS; + using std::erfcf _LIBCPP_USING_IF_EXISTS; + using std::erfcl _LIBCPP_USING_IF_EXISTS; - using std::lgamma; - using std::lgammaf; - using std::lgammal; + using std::lgamma _LIBCPP_USING_IF_EXISTS; + using std::lgammaf _LIBCPP_USING_IF_EXISTS; + using std::lgammal _LIBCPP_USING_IF_EXISTS; - using std::tgamma; - using std::tgammaf; - using std::tgammal; + using std::tgamma _LIBCPP_USING_IF_EXISTS; + using std::tgammaf _LIBCPP_USING_IF_EXISTS; + using std::tgammal _LIBCPP_USING_IF_EXISTS; - using std::ceil; - using std::ceilf; - using std::ceill; + using std::ceil _LIBCPP_USING_IF_EXISTS; + using std::ceilf _LIBCPP_USING_IF_EXISTS; + using std::ceill _LIBCPP_USING_IF_EXISTS; - using std::floor; - using std::floorf; - using std::floorl; + using std::floor _LIBCPP_USING_IF_EXISTS; + using std::floorf _LIBCPP_USING_IF_EXISTS; + using std::floorl _LIBCPP_USING_IF_EXISTS; - using std::nearbyint; - using std::nearbyintf; - using std::nearbyintl; + using std::nearbyint _LIBCPP_USING_IF_EXISTS; + using std::nearbyintf _LIBCPP_USING_IF_EXISTS; + using std::nearbyintl _LIBCPP_USING_IF_EXISTS; - using std::rint; - using std::rintf; - using std::rintl; + using std::rint _LIBCPP_USING_IF_EXISTS; + using std::rintf _LIBCPP_USING_IF_EXISTS; + using std::rintl _LIBCPP_USING_IF_EXISTS; - using std::lrint; - using std::lrintf; - using std::lrintl; + using std::lrint _LIBCPP_USING_IF_EXISTS; + using std::lrintf _LIBCPP_USING_IF_EXISTS; + using std::lrintl _LIBCPP_USING_IF_EXISTS; - using std::llrint; - using std::llrintf; - using std::llrintl; + using std::llrint _LIBCPP_USING_IF_EXISTS; + using std::llrintf _LIBCPP_USING_IF_EXISTS; + using std::llrintl _LIBCPP_USING_IF_EXISTS; - using std::round; - using std::roundf; - using std::roundl; + using std::round _LIBCPP_USING_IF_EXISTS; + using std::roundf _LIBCPP_USING_IF_EXISTS; + using std::roundl _LIBCPP_USING_IF_EXISTS; - using std::lround; - using std::lroundf; - using std::lroundl; + using std::lround _LIBCPP_USING_IF_EXISTS; + using std::lroundf _LIBCPP_USING_IF_EXISTS; + using std::lroundl _LIBCPP_USING_IF_EXISTS; - using std::llround; - using std::llroundf; - using std::llroundl; + using std::llround _LIBCPP_USING_IF_EXISTS; + using std::llroundf _LIBCPP_USING_IF_EXISTS; + using std::llroundl _LIBCPP_USING_IF_EXISTS; - using std::trunc; - using std::truncf; - using std::truncl; + using std::trunc _LIBCPP_USING_IF_EXISTS; + using std::truncf _LIBCPP_USING_IF_EXISTS; + using std::truncl _LIBCPP_USING_IF_EXISTS; - using std::fmod; - using std::fmodf; - using std::fmodl; + using std::fmod _LIBCPP_USING_IF_EXISTS; + using std::fmodf _LIBCPP_USING_IF_EXISTS; + using std::fmodl _LIBCPP_USING_IF_EXISTS; - using std::remainder; - using std::remainderf; - using std::remainderl; + using std::remainder _LIBCPP_USING_IF_EXISTS; + using std::remainderf _LIBCPP_USING_IF_EXISTS; + using std::remainderl _LIBCPP_USING_IF_EXISTS; - using std::remquo; - using std::remquof; - using std::remquol; + using std::remquo _LIBCPP_USING_IF_EXISTS; + using std::remquof _LIBCPP_USING_IF_EXISTS; + using std::remquol _LIBCPP_USING_IF_EXISTS; - using std::copysign; - using std::copysignf; - using std::copysignl; + using std::copysign _LIBCPP_USING_IF_EXISTS; + using std::copysignf _LIBCPP_USING_IF_EXISTS; + using std::copysignl _LIBCPP_USING_IF_EXISTS; - using std::nan; - using std::nanf; - using std::nanl; + using std::nan _LIBCPP_USING_IF_EXISTS; + using std::nanf _LIBCPP_USING_IF_EXISTS; + using std::nanl _LIBCPP_USING_IF_EXISTS; - using std::nextafter; - using std::nextafterf; - using std::nextafterl; + using std::nextafter _LIBCPP_USING_IF_EXISTS; + using std::nextafterf _LIBCPP_USING_IF_EXISTS; + using std::nextafterl _LIBCPP_USING_IF_EXISTS; - using std::nexttoward; - using std::nexttowardf; - using std::nexttowardl; + using std::nexttoward _LIBCPP_USING_IF_EXISTS; + using std::nexttowardf _LIBCPP_USING_IF_EXISTS; + using std::nexttowardl _LIBCPP_USING_IF_EXISTS; - using std::fdim; - using std::fdimf; - using std::fdiml; + using std::fdim _LIBCPP_USING_IF_EXISTS; + using std::fdimf _LIBCPP_USING_IF_EXISTS; + using std::fdiml _LIBCPP_USING_IF_EXISTS; - using std::fmax; - using std::fmaxf; - using std::fmaxl; + using std::fmax _LIBCPP_USING_IF_EXISTS; + using std::fmaxf _LIBCPP_USING_IF_EXISTS; + using std::fmaxl _LIBCPP_USING_IF_EXISTS; - using std::fmin; - using std::fminf; - using std::fminl; + using std::fmin _LIBCPP_USING_IF_EXISTS; + using std::fminf _LIBCPP_USING_IF_EXISTS; + using std::fminl _LIBCPP_USING_IF_EXISTS; - using std::fma; - using std::fmaf; - using std::fmal; + using std::fma _LIBCPP_USING_IF_EXISTS; + using std::fmaf _LIBCPP_USING_IF_EXISTS; + using std::fmal _LIBCPP_USING_IF_EXISTS; // [c.math.lerp], linear interpolation - using std::lerp; + using std::lerp _LIBCPP_USING_IF_EXISTS; // [c.math.fpclass], classification / comparison functions - using std::fpclassify; - using std::isfinite; - using std::isgreater; - using std::isgreaterequal; - using std::isinf; - using std::isless; - using std::islessequal; - using std::islessgreater; - using std::isnan; - using std::isnormal; - using std::isunordered; - using std::signbit; + using std::fpclassify _LIBCPP_USING_IF_EXISTS; + using std::isfinite _LIBCPP_USING_IF_EXISTS; + using std::isgreater _LIBCPP_USING_IF_EXISTS; + using std::isgreaterequal _LIBCPP_USING_IF_EXISTS; + using std::isinf _LIBCPP_USING_IF_EXISTS; + using std::isless _LIBCPP_USING_IF_EXISTS; + using std::islessequal _LIBCPP_USING_IF_EXISTS; + using std::islessgreater _LIBCPP_USING_IF_EXISTS; + using std::isnan _LIBCPP_USING_IF_EXISTS; + using std::isnormal _LIBCPP_USING_IF_EXISTS; + using std::isunordered _LIBCPP_USING_IF_EXISTS; + using std::signbit _LIBCPP_USING_IF_EXISTS; // [sf.cmath], mathematical special functions #if 0 diff --git a/libcxx/modules/std/csetjmp.inc b/libcxx/modules/std/csetjmp.inc index 68e226c8b7f1cc..8aa2e232929153 100644 --- a/libcxx/modules/std/csetjmp.inc +++ b/libcxx/modules/std/csetjmp.inc @@ -8,6 +8,6 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::jmp_buf; - using std::longjmp; + using std::jmp_buf _LIBCPP_USING_IF_EXISTS; + using std::longjmp _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/csignal.inc b/libcxx/modules/std/csignal.inc index b57e8edc6c0946..05f3986866c7be 100644 --- a/libcxx/modules/std/csignal.inc +++ b/libcxx/modules/std/csignal.inc @@ -8,11 +8,11 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::sig_atomic_t; + using std::sig_atomic_t _LIBCPP_USING_IF_EXISTS; // [support.signal], signal handlers - using std::signal; + using std::signal _LIBCPP_USING_IF_EXISTS; - using std::raise; + using std::raise _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cstdarg.inc b/libcxx/modules/std/cstdarg.inc index 2b7309c94ed268..5947bc2452b711 100644 --- a/libcxx/modules/std/cstdarg.inc +++ b/libcxx/modules/std/cstdarg.inc @@ -8,5 +8,5 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::va_list; + using std::va_list _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cstddef.inc b/libcxx/modules/std/cstddef.inc index 2b9ab0c4707467..6443de89238239 100644 --- a/libcxx/modules/std/cstddef.inc +++ b/libcxx/modules/std/cstddef.inc @@ -8,10 +8,10 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::max_align_t; + using std::max_align_t _LIBCPP_USING_IF_EXISTS; using std::nullptr_t; - using std::ptrdiff_t; - using std::size_t; + using std::ptrdiff_t _LIBCPP_USING_IF_EXISTS; + using std::size_t _LIBCPP_USING_IF_EXISTS; using std::byte; diff --git a/libcxx/modules/std/cstdint.inc b/libcxx/modules/std/cstdint.inc index f6de4472218dac..f23b52a94526eb 100644 --- a/libcxx/modules/std/cstdint.inc +++ b/libcxx/modules/std/cstdint.inc @@ -14,17 +14,17 @@ export namespace std { using std::int32_t _LIBCPP_USING_IF_EXISTS; using std::int64_t _LIBCPP_USING_IF_EXISTS; - using std::int_fast16_t; - using std::int_fast32_t; - using std::int_fast64_t; - using std::int_fast8_t; + using std::int_fast16_t _LIBCPP_USING_IF_EXISTS; + using std::int_fast32_t _LIBCPP_USING_IF_EXISTS; + using std::int_fast64_t _LIBCPP_USING_IF_EXISTS; + using std::int_fast8_t _LIBCPP_USING_IF_EXISTS; - using std::int_least16_t; - using std::int_least32_t; - using std::int_least64_t; - using std::int_least8_t; + using std::int_least16_t _LIBCPP_USING_IF_EXISTS; + using std::int_least32_t _LIBCPP_USING_IF_EXISTS; + using std::int_least64_t _LIBCPP_USING_IF_EXISTS; + using std::int_least8_t _LIBCPP_USING_IF_EXISTS; - using std::intmax_t; + using std::intmax_t _LIBCPP_USING_IF_EXISTS; using std::intptr_t _LIBCPP_USING_IF_EXISTS; @@ -34,17 +34,17 @@ export namespace std { using std::uint32_t _LIBCPP_USING_IF_EXISTS; using std::uint64_t _LIBCPP_USING_IF_EXISTS; - using std::uint_fast16_t; - using std::uint_fast32_t; - using std::uint_fast64_t; - using std::uint_fast8_t; + using std::uint_fast16_t _LIBCPP_USING_IF_EXISTS; + using std::uint_fast32_t _LIBCPP_USING_IF_EXISTS; + using std::uint_fast64_t _LIBCPP_USING_IF_EXISTS; + using std::uint_fast8_t _LIBCPP_USING_IF_EXISTS; - using std::uint_least16_t; - using std::uint_least32_t; - using std::uint_least64_t; - using std::uint_least8_t; + using std::uint_least16_t _LIBCPP_USING_IF_EXISTS; + using std::uint_least32_t _LIBCPP_USING_IF_EXISTS; + using std::uint_least64_t _LIBCPP_USING_IF_EXISTS; + using std::uint_least8_t _LIBCPP_USING_IF_EXISTS; - using std::uintmax_t; + using std::uintmax_t _LIBCPP_USING_IF_EXISTS; using std::uintptr_t _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cstdio.inc b/libcxx/modules/std/cstdio.inc index eec8170e079175..62fa2f566a5f62 100644 --- a/libcxx/modules/std/cstdio.inc +++ b/libcxx/modules/std/cstdio.inc @@ -8,53 +8,53 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::FILE; - using std::fpos_t; - using std::size_t; + using std::FILE _LIBCPP_USING_IF_EXISTS; + using std::fpos_t _LIBCPP_USING_IF_EXISTS; + using std::size_t _LIBCPP_USING_IF_EXISTS; - using std::clearerr; - using std::fclose; - using std::feof; - using std::ferror; - using std::fflush; - using std::fgetc; - using std::fgetpos; - using std::fgets; - using std::fopen; - using std::fprintf; - using std::fputc; - using std::fputs; - using std::fread; - using std::freopen; - using std::fscanf; - using std::fseek; - using std::fsetpos; - using std::ftell; - using std::fwrite; - using std::getc; - using std::getchar; - using std::perror; - using std::printf; - using std::putc; - using std::putchar; - using std::puts; - using std::remove; - using std::rename; - using std::rewind; - using std::scanf; - using std::setbuf; - using std::setvbuf; - using std::snprintf; - using std::sprintf; - using std::sscanf; - using std::tmpfile; - using std::tmpnam; - using std::ungetc; - using std::vfprintf; - using std::vfscanf; - using std::vprintf; - using std::vscanf; - using std::vsnprintf; - using std::vsprintf; - using std::vsscanf; + using std::clearerr _LIBCPP_USING_IF_EXISTS; + using std::fclose _LIBCPP_USING_IF_EXISTS; + using std::feof _LIBCPP_USING_IF_EXISTS; + using std::ferror _LIBCPP_USING_IF_EXISTS; + using std::fflush _LIBCPP_USING_IF_EXISTS; + using std::fgetc _LIBCPP_USING_IF_EXISTS; + using std::fgetpos _LIBCPP_USING_IF_EXISTS; + using std::fgets _LIBCPP_USING_IF_EXISTS; + using std::fopen _LIBCPP_USING_IF_EXISTS; + using std::fprintf _LIBCPP_USING_IF_EXISTS; + using std::fputc _LIBCPP_USING_IF_EXISTS; + using std::fputs _LIBCPP_USING_IF_EXISTS; + using std::fread _LIBCPP_USING_IF_EXISTS; + using std::freopen _LIBCPP_USING_IF_EXISTS; + using std::fscanf _LIBCPP_USING_IF_EXISTS; + using std::fseek _LIBCPP_USING_IF_EXISTS; + using std::fsetpos _LIBCPP_USING_IF_EXISTS; + using std::ftell _LIBCPP_USING_IF_EXISTS; + using std::fwrite _LIBCPP_USING_IF_EXISTS; + using std::getc _LIBCPP_USING_IF_EXISTS; + using std::getchar _LIBCPP_USING_IF_EXISTS; + using std::perror _LIBCPP_USING_IF_EXISTS; + using std::printf _LIBCPP_USING_IF_EXISTS; + using std::putc _LIBCPP_USING_IF_EXISTS; + using std::putchar _LIBCPP_USING_IF_EXISTS; + using std::puts _LIBCPP_USING_IF_EXISTS; + using std::remove _LIBCPP_USING_IF_EXISTS; + using std::rename _LIBCPP_USING_IF_EXISTS; + using std::rewind _LIBCPP_USING_IF_EXISTS; + using std::scanf _LIBCPP_USING_IF_EXISTS; + using std::setbuf _LIBCPP_USING_IF_EXISTS; + using std::setvbuf _LIBCPP_USING_IF_EXISTS; + using std::snprintf _LIBCPP_USING_IF_EXISTS; + using std::sprintf _LIBCPP_USING_IF_EXISTS; + using std::sscanf _LIBCPP_USING_IF_EXISTS; + using std::tmpfile _LIBCPP_USING_IF_EXISTS; + using std::tmpnam _LIBCPP_USING_IF_EXISTS; + using std::ungetc _LIBCPP_USING_IF_EXISTS; + using std::vfprintf _LIBCPP_USING_IF_EXISTS; + using std::vfscanf _LIBCPP_USING_IF_EXISTS; + using std::vprintf _LIBCPP_USING_IF_EXISTS; + using std::vscanf _LIBCPP_USING_IF_EXISTS; + using std::vsnprintf _LIBCPP_USING_IF_EXISTS; + using std::vsprintf _LIBCPP_USING_IF_EXISTS; + using std::vsscanf _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cstdlib.inc b/libcxx/modules/std/cstdlib.inc index 8840c61367c30c..617cf3ff3ef6b7 100644 --- a/libcxx/modules/std/cstdlib.inc +++ b/libcxx/modules/std/cstdlib.inc @@ -8,64 +8,64 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::div_t; - using std::ldiv_t; - using std::lldiv_t; - using std::size_t; + using std::div_t _LIBCPP_USING_IF_EXISTS; + using std::ldiv_t _LIBCPP_USING_IF_EXISTS; + using std::lldiv_t _LIBCPP_USING_IF_EXISTS; + using std::size_t _LIBCPP_USING_IF_EXISTS; // [support.start.term], start and termination - using std::_Exit; - using std::abort; - using std::at_quick_exit; - using std::atexit; - using std::exit; - using std::quick_exit; + using std::_Exit _LIBCPP_USING_IF_EXISTS; + using std::abort _LIBCPP_USING_IF_EXISTS; + using std::at_quick_exit _LIBCPP_USING_IF_EXISTS; + using std::atexit _LIBCPP_USING_IF_EXISTS; + using std::exit _LIBCPP_USING_IF_EXISTS; + using std::quick_exit _LIBCPP_USING_IF_EXISTS; - using std::getenv; - using std::system; + using std::getenv _LIBCPP_USING_IF_EXISTS; + using std::system _LIBCPP_USING_IF_EXISTS; // [c.malloc], C library memory allocation - using std::aligned_alloc; - using std::calloc; - using std::free; - using std::malloc; - using std::realloc; + using std::aligned_alloc _LIBCPP_USING_IF_EXISTS; + using std::calloc _LIBCPP_USING_IF_EXISTS; + using std::free _LIBCPP_USING_IF_EXISTS; + using std::malloc _LIBCPP_USING_IF_EXISTS; + using std::realloc _LIBCPP_USING_IF_EXISTS; - using std::atof; - using std::atoi; - using std::atol; - using std::atoll; - using std::strtod; - using std::strtof; - using std::strtol; - using std::strtold; - using std::strtoll; - using std::strtoul; - using std::strtoull; + using std::atof _LIBCPP_USING_IF_EXISTS; + using std::atoi _LIBCPP_USING_IF_EXISTS; + using std::atol _LIBCPP_USING_IF_EXISTS; + using std::atoll _LIBCPP_USING_IF_EXISTS; + using std::strtod _LIBCPP_USING_IF_EXISTS; + using std::strtof _LIBCPP_USING_IF_EXISTS; + using std::strtol _LIBCPP_USING_IF_EXISTS; + using std::strtold _LIBCPP_USING_IF_EXISTS; + using std::strtoll _LIBCPP_USING_IF_EXISTS; + using std::strtoul _LIBCPP_USING_IF_EXISTS; + using std::strtoull _LIBCPP_USING_IF_EXISTS; // [c.mb.wcs], multibyte / wide string and character conversion functions - using std::mblen; + using std::mblen _LIBCPP_USING_IF_EXISTS; #ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS - using std::mbstowcs; - using std::mbtowc; - using std::wcstombs; - using std::wctomb; + using std::mbstowcs _LIBCPP_USING_IF_EXISTS; + using std::mbtowc _LIBCPP_USING_IF_EXISTS; + using std::wcstombs _LIBCPP_USING_IF_EXISTS; + using std::wctomb _LIBCPP_USING_IF_EXISTS; #endif // [alg.c.library], C standard library algorithms - using std::bsearch; - using std::qsort; + using std::bsearch _LIBCPP_USING_IF_EXISTS; + using std::qsort _LIBCPP_USING_IF_EXISTS; // [c.math.rand], low-quality random number generation - using std::rand; - using std::srand; + using std::rand _LIBCPP_USING_IF_EXISTS; + using std::srand _LIBCPP_USING_IF_EXISTS; // [c.math.abs], absolute values - using std::abs; + using std::abs _LIBCPP_USING_IF_EXISTS; - using std::labs; - using std::llabs; + using std::labs _LIBCPP_USING_IF_EXISTS; + using std::llabs _LIBCPP_USING_IF_EXISTS; - using std::div; - using std::ldiv; - using std::lldiv; + using std::div _LIBCPP_USING_IF_EXISTS; + using std::ldiv _LIBCPP_USING_IF_EXISTS; + using std::lldiv _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cstring.inc b/libcxx/modules/std/cstring.inc index d21714b787c812..9ad33b982b32af 100644 --- a/libcxx/modules/std/cstring.inc +++ b/libcxx/modules/std/cstring.inc @@ -8,28 +8,28 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::size_t; + using std::size_t _LIBCPP_USING_IF_EXISTS; - using std::memchr; - using std::memcmp; - using std::memcpy; - using std::memmove; - using std::memset; - using std::strcat; - using std::strchr; - using std::strcmp; - using std::strcoll; - using std::strcpy; - using std::strcspn; - using std::strerror; - using std::strlen; - using std::strncat; - using std::strncmp; - using std::strncpy; - using std::strpbrk; - using std::strrchr; - using std::strspn; - using std::strstr; - using std::strtok; - using std::strxfrm; + using std::memchr _LIBCPP_USING_IF_EXISTS; + using std::memcmp _LIBCPP_USING_IF_EXISTS; + using std::memcpy _LIBCPP_USING_IF_EXISTS; + using std::memmove _LIBCPP_USING_IF_EXISTS; + using std::memset _LIBCPP_USING_IF_EXISTS; + using std::strcat _LIBCPP_USING_IF_EXISTS; + using std::strchr _LIBCPP_USING_IF_EXISTS; + using std::strcmp _LIBCPP_USING_IF_EXISTS; + using std::strcoll _LIBCPP_USING_IF_EXISTS; + using std::strcpy _LIBCPP_USING_IF_EXISTS; + using std::strcspn _LIBCPP_USING_IF_EXISTS; + using std::strerror _LIBCPP_USING_IF_EXISTS; + using std::strlen _LIBCPP_USING_IF_EXISTS; + using std::strncat _LIBCPP_USING_IF_EXISTS; + using std::strncmp _LIBCPP_USING_IF_EXISTS; + using std::strncpy _LIBCPP_USING_IF_EXISTS; + using std::strpbrk _LIBCPP_USING_IF_EXISTS; + using std::strrchr _LIBCPP_USING_IF_EXISTS; + using std::strspn _LIBCPP_USING_IF_EXISTS; + using std::strstr _LIBCPP_USING_IF_EXISTS; + using std::strtok _LIBCPP_USING_IF_EXISTS; + using std::strxfrm _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/ctime.inc b/libcxx/modules/std/ctime.inc index c98cb28e649b85..5bfa61917e5f20 100644 --- a/libcxx/modules/std/ctime.inc +++ b/libcxx/modules/std/ctime.inc @@ -8,21 +8,21 @@ //===----------------------------------------------------------------------===// export namespace std { - using std::clock_t; - using std::size_t; - using std::time_t; + using std::clock_t _LIBCPP_USING_IF_EXISTS; + using std::size_t _LIBCPP_USING_IF_EXISTS; + using std::time_t _LIBCPP_USING_IF_EXISTS; - using std::timespec; - using std::tm; + using std::timespec _LIBCPP_USING_IF_EXISTS; + using std::tm _LIBCPP_USING_IF_EXISTS; - using std::asctime; - using std::clock; - using std::ctime; - using std::difftime; - using std::gmtime; - using std::localtime; - using std::mktime; - using std::strftime; - using std::time; + using std::asctime _LIBCPP_USING_IF_EXISTS; + using std::clock _LIBCPP_USING_IF_EXISTS; + using std::ctime _LIBCPP_USING_IF_EXISTS; + using std::difftime _LIBCPP_USING_IF_EXISTS; + using std::gmtime _LIBCPP_USING_IF_EXISTS; + using std::localtime _LIBCPP_USING_IF_EXISTS; + using std::mktime _LIBCPP_USING_IF_EXISTS; + using std::strftime _LIBCPP_USING_IF_EXISTS; + using std::time _LIBCPP_USING_IF_EXISTS; using std::timespec_get _LIBCPP_USING_IF_EXISTS; } // namespace std diff --git a/libcxx/modules/std/cwchar.inc b/libcxx/modules/std/cwchar.inc index 6818c46b48ef31..02b1713359b6aa 100644 --- a/libcxx/modules/std/cwchar.inc +++ b/libcxx/modules/std/cwchar.inc @@ -9,72 +9,72 @@ export namespace std { #ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS - using std::mbstate_t; - using std::size_t; - using std::wint_t; + using std::mbstate_t _LIBCPP_USING_IF_EXISTS; + using std::size_t _LIBCPP_USING_IF_EXISTS; + using std::wint_t _LIBCPP_USING_IF_EXISTS; - using std::tm; + using std::tm _LIBCPP_USING_IF_EXISTS; - using std::btowc; - using std::fgetwc; - using std::fgetws; - using std::fputwc; - using std::fputws; - using std::fwide; - using std::fwprintf; - using std::fwscanf; - using std::getwc; - using std::getwchar; - using std::putwc; - using std::putwchar; - using std::swprintf; - using std::swscanf; - using std::ungetwc; - using std::vfwprintf; - using std::vfwscanf; - using std::vswprintf; - using std::vswscanf; - using std::vwprintf; - using std::vwscanf; - using std::wcscat; - using std::wcschr; - using std::wcscmp; - using std::wcscoll; - using std::wcscpy; - using std::wcscspn; - using std::wcsftime; - using std::wcslen; - using std::wcsncat; - using std::wcsncmp; - using std::wcsncpy; - using std::wcspbrk; - using std::wcsrchr; - using std::wcsspn; - using std::wcsstr; - using std::wcstod; - using std::wcstof; - using std::wcstok; - using std::wcstol; - using std::wcstold; - using std::wcstoll; - using std::wcstoul; - using std::wcstoull; - using std::wcsxfrm; - using std::wctob; - using std::wmemchr; - using std::wmemcmp; - using std::wmemcpy; - using std::wmemmove; - using std::wmemset; - using std::wprintf; - using std::wscanf; + using std::btowc _LIBCPP_USING_IF_EXISTS; + using std::fgetwc _LIBCPP_USING_IF_EXISTS; + using std::fgetws _LIBCPP_USING_IF_EXISTS; + using std::fputwc _LIBCPP_USING_IF_EXISTS; + using std::fputws _LIBCPP_USING_IF_EXISTS; + using std::fwide _LIBCPP_USING_IF_EXISTS; + using std::fwprintf _LIBCPP_USING_IF_EXISTS; + using std::fwscanf _LIBCPP_USING_IF_EXISTS; + using std::getwc _LIBCPP_USING_IF_EXISTS; + using std::getwchar _LIBCPP_USING_IF_EXISTS; + using std::putwc _LIBCPP_USING_IF_EXISTS; + using std::putwchar _LIBCPP_USING_IF_EXISTS; + using std::swprintf _LIBCPP_USING_IF_EXISTS; + using std::swscanf _LIBCPP_USING_IF_EXISTS; + using std::ungetwc _LIBCPP_USING_IF_EXISTS; + using std::vfwprintf _LIBCPP_USING_IF_EXISTS; + using std::vfwscanf _LIBCPP_USING_IF_EXISTS; + using std::vswprintf _LIBCPP_USING_IF_EXISTS; + using std::vswscanf _LIBCPP_USING_IF_EXISTS; + using std::vwprintf _LIBCPP_USING_IF_EXISTS; + using std::vwscanf _LIBCPP_USING_IF_EXISTS; + using std::wcscat _LIBCPP_USING_IF_EXISTS; + using std::wcschr _LIBCPP_USING_IF_EXISTS; + using std::wcscmp _LIBCPP_USING_IF_EXISTS; + using std::wcscoll _LIBCPP_USING_IF_EXISTS; + using std::wcscpy _LIBCPP_USING_IF_EXISTS; + using std::wcscspn _LIBCPP_USING_IF_EXISTS; + using std::wcsftime _LIBCPP_USING_IF_EXISTS; + using std::wcslen _LIBCPP_USING_IF_EXISTS; + using std::wcsncat _LIBCPP_USING_IF_EXISTS; + using std::wcsncmp _LIBCPP_USING_IF_EXISTS; + using std::wcsncpy _LIBCPP_USING_IF_EXISTS; + using std::wcspbrk _LIBCPP_USING_IF_EXISTS; + using std::wcsrchr _LIBCPP_USING_IF_EXISTS; + using std::wcsspn _LIBCPP_USING_IF_EXISTS; + using std::wcsstr _LIBCPP_USING_IF_EXISTS; + using std::wcstod _LIBCPP_USING_IF_EXISTS; + using std::wcstof _LIBCPP_USING_IF_EXISTS; + using std::wcstok _LIBCPP_USING_IF_EXISTS; + using std::wcstol _LIBCPP_USING_IF_EXISTS; + using std::wcstold _LIBCPP_USING_IF_EXISTS; + using std::wcstoll _LIBCPP_USING_IF_EXISTS; + using std::wcstoul _LIBCPP_USING_IF_EXISTS; + using std::wcstoull _LIBCPP_USING_IF_EXISTS; + using std::wcsxfrm _LIBCPP_USING_IF_EXISTS; + using std::wctob _LIBCPP_USING_IF_EXISTS; + using std::wmemchr _LIBCPP_USING_IF_EXISTS; + using std::wmemcmp _LIBCPP_USING_IF_EXISTS; + using std::wmemcpy _LIBCPP_USING_IF_EXISTS; + using std::wmemmove _LIBCPP_USING_IF_EXISTS; + using std::wmemset _LIBCPP_USING_IF_EXISTS; + using std::wprintf _LIBCPP_USING_IF_EXISTS; + using std::wscanf _LIBCPP_USING_IF_EXISTS; // [c.mb.wcs], multibyte / wide string and character conversion functions - using std::mbrlen; - using std::mbrtowc; - using std::mbsinit; - using std::mbsrtowcs; - using std::wcrtomb; - using std::wcsrtombs; + using std::mbrlen _LIBCPP_USING_IF_EXISTS; + using std::mbrtowc _LIBCPP_USING_IF_EXISTS; + using std::mbsinit _LIBCPP_USING_IF_EXISTS; + using std::mbsrtowcs _LIBCPP_USING_IF_EXISTS; + using std::wcrtomb _LIBCPP_USING_IF_EXISTS; + using std::wcsrtombs _LIBCPP_USING_IF_EXISTS; #endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS } // namespace std diff --git a/libcxx/modules/std/cwctype.inc b/libcxx/modules/std/cwctype.inc index 70e6cf3f113374..30e526aae0af6f 100644 --- a/libcxx/modules/std/cwctype.inc +++ b/libcxx/modules/std/cwctype.inc @@ -9,27 +9,27 @@ export namespace std { #ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS - using std::wctrans_t; - using std::wctype_t; - using std::wint_t; + using std::wctrans_t _LIBCPP_USING_IF_EXISTS; + using std::wctype_t _LIBCPP_USING_IF_EXISTS; + using std::wint_t _LIBCPP_USING_IF_EXISTS; - using std::iswalnum; - using std::iswalpha; - using std::iswblank; - using std::iswcntrl; - using std::iswctype; - using std::iswdigit; - using std::iswgraph; - using std::iswlower; - using std::iswprint; - using std::iswpunct; - using std::iswspace; - using std::iswupper; - using std::iswxdigit; - using std::towctrans; - using std::towlower; - using std::towupper; - using std::wctrans; - using std::wctype; + using std::iswalnum _LIBCPP_USING_IF_EXISTS; + using std::iswalpha _LIBCPP_USING_IF_EXISTS; + using std::iswblank _LIBCPP_USING_IF_EXISTS; + using std::iswcntrl _LIBCPP_USING_IF_EXISTS; + using std::iswctype _LIBCPP_USING_IF_EXISTS; + using std::iswdigit _LIBCPP_USING_IF_EXISTS; + using std::iswgraph _LIBCPP_USING_IF_EXISTS; + using std::iswlower _LIBCPP_USING_IF_EXISTS; + using std::iswprint _LIBCPP_USING_IF_EXISTS; + using std::iswpunct _LIBCPP_USING_IF_EXISTS; + using std::iswspace _LIBCPP_USING_IF_EXISTS; + using std::iswupper _LIBCPP_USING_IF_EXISTS; + using std::iswxdigit _LIBCPP_USING_IF_EXISTS; + using std::towctrans _LIBCPP_USING_IF_EXISTS; + using std::towlower _LIBCPP_USING_IF_EXISTS; + using std::towupper _LIBCPP_USING_IF_EXISTS; + using std::wctrans _LIBCPP_USING_IF_EXISTS; + using std::wctype _LIBCPP_USING_IF_EXISTS; #endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS } // namespace std