From 90a8bda23077508ca208e7afc535da1e2c7d59ae Mon Sep 17 00:00:00 2001 From: Yuriy Chernyshov Date: Thu, 25 Jul 2024 22:50:40 +0300 Subject: [PATCH 1/3] Workaround broken compilation against NDK r25 --- absl/time/time.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/absl/time/time.h b/absl/time/time.h index f133c2d2ca8..15edbb4a667 100644 --- a/absl/time/time.h +++ b/absl/time/time.h @@ -76,9 +76,9 @@ struct timeval; #endif #include // NOLINT(build/c++11) -#ifdef __cpp_impl_three_way_comparison +#ifdef __cpp_lib_three_way_comparison #include -#endif // __cpp_impl_three_way_comparison +#endif // __cpp_lib_three_way_comparison #include #include @@ -313,12 +313,12 @@ class Duration { // Relational Operators -#ifdef __cpp_impl_three_way_comparison +#ifdef __cpp_lib_three_way_comparison ABSL_ATTRIBUTE_CONST_FUNCTION constexpr std::strong_ordering operator<=>( Duration lhs, Duration rhs); -#endif // __cpp_impl_three_way_comparison +#endif // __cpp_lib_three_way_comparison ABSL_ATTRIBUTE_CONST_FUNCTION constexpr bool operator<(Duration lhs, Duration rhs); @@ -853,9 +853,9 @@ class Time { friend constexpr Time time_internal::FromUnixDuration(Duration d); friend constexpr Duration time_internal::ToUnixDuration(Time t); -#ifdef __cpp_impl_three_way_comparison +#ifdef __cpp_lib_three_way_comparison friend constexpr std::strong_ordering operator<=>(Time lhs, Time rhs); -#endif // __cpp_impl_three_way_comparison +#endif // __cpp_lib_three_way_comparison friend constexpr bool operator<(Time lhs, Time rhs); friend constexpr bool operator==(Time lhs, Time rhs); @@ -868,14 +868,14 @@ class Time { }; // Relational Operators -#ifdef __cpp_impl_three_way_comparison +#ifdef __cpp_lib_three_way_comparison ABSL_ATTRIBUTE_CONST_FUNCTION constexpr std::strong_ordering operator<=>( Time lhs, Time rhs) { return lhs.rep_ <=> rhs.rep_; } -#endif // __cpp_impl_three_way_comparison +#endif // __cpp_lib_three_way_comparison ABSL_ATTRIBUTE_CONST_FUNCTION constexpr bool operator<(Time lhs, Time rhs) { return lhs.rep_ < rhs.rep_; @@ -1753,7 +1753,7 @@ ABSL_ATTRIBUTE_CONST_FUNCTION constexpr bool operator<(Duration lhs, } -#ifdef __cpp_impl_three_way_comparison +#ifdef __cpp_lib_three_way_comparison ABSL_ATTRIBUTE_CONST_FUNCTION constexpr std::strong_ordering operator<=>( Duration lhs, Duration rhs) { @@ -1769,7 +1769,7 @@ ABSL_ATTRIBUTE_CONST_FUNCTION constexpr std::strong_ordering operator<=>( : lhs_lo <=> rhs_lo; } -#endif // __cpp_impl_three_way_comparison +#endif // __cpp_lib_three_way_comparison ABSL_ATTRIBUTE_CONST_FUNCTION constexpr bool operator==(Duration lhs, Duration rhs) {