[libcxx-commits] [libcxx] 06edc1c - [libc++] Avoid including <__config> directly in the test suite (#106080)
via libcxx-commits
libcxx-commits at lists.llvm.org
Mon Aug 26 14:52:37 PDT 2024
Author: Louis Dionne
Date: 2024-08-26T17:52:33-04:00
New Revision: 06edc1c07b447b6a2c5c70dafa24c4d6b8b3390f
URL: https://github.com/llvm/llvm-project/commit/06edc1c07b447b6a2c5c70dafa24c4d6b8b3390f
DIFF: https://github.com/llvm/llvm-project/commit/06edc1c07b447b6a2c5c70dafa24c4d6b8b3390f.diff
LOG: [libc++] Avoid including <__config> directly in the test suite (#106080)
Fixes #105878
Added:
Modified:
libcxx/test/support/fp_compare.h
Removed:
################################################################################
diff --git a/libcxx/test/support/fp_compare.h b/libcxx/test/support/fp_compare.h
index 3088a211dadc3b..237ee50d1f66b5 100644
--- a/libcxx/test/support/fp_compare.h
+++ b/libcxx/test/support/fp_compare.h
@@ -9,16 +9,17 @@
#ifndef SUPPORT_FP_COMPARE_H
#define SUPPORT_FP_COMPARE_H
-#include <cmath> // for std::abs
#include <algorithm> // for std::max
#include <cassert>
-#include <__config>
+#include <cmath> // for std::abs
+
+#include "test_macros.h"
// See https://www.boost.org/doc/libs/1_70_0/libs/test/doc/html/boost_test/testing_tools/extended_comparison/floating_point/floating_points_comparison_theory.html
template <typename T>
bool fptest_close(T val, T expected, T eps) {
- _LIBCPP_CONSTEXPR T zero = T(0);
+ TEST_CONSTEXPR T zero = T(0);
assert(eps >= zero);
// Handle the zero cases
More information about the libcxx-commits
mailing list