Skip to content

Commit cee1e7d

Browse files
author
Siva Chandra Reddy
committed
[libc][NFC][Obvious] Remove few unnecessary #include directives in tests.
1 parent 4f14b80 commit cee1e7d

15 files changed

+5
-36
lines changed

libc/test/src/math/HypotTest.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,14 @@
99
#ifndef LLVM_LIBC_TEST_SRC_MATH_HYPOTTEST_H
1010
#define LLVM_LIBC_TEST_SRC_MATH_HYPOTTEST_H
1111

12-
#include "include/math.h"
1312
#include "utils/FPUtil/FPBits.h"
1413
#include "utils/FPUtil/Hypot.h"
1514
#include "utils/FPUtil/TestHelpers.h"
1615
#include "utils/MPFRWrapper/MPFRUtils.h"
1716
#include "utils/UnitTest/Test.h"
1817

18+
#include <math.h>
19+
1920
namespace mpfr = __llvm_libc::testing::mpfr;
2021

2122
template <typename T>

libc/test/src/math/RoundToIntegerTest.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
#include "src/fenv/feclearexcept.h"
1414
#include "src/fenv/feraiseexcept.h"
1515
#include "src/fenv/fetestexcept.h"
16-
#include "utils/CPP/TypeTraits.h"
1716
#include "utils/FPUtil/FPBits.h"
1817
#include "utils/MPFRWrapper/MPFRUtils.h"
1918
#include "utils/UnitTest/Test.h"

libc/test/src/math/hypot_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "HypotTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/hypot.h"
1312

1413
using HypotTest = HypotTestTemplate<double>;

libc/test/src/math/hypotf_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "HypotTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/hypotf.h"
1312

1413
using HypotfTest = HypotTestTemplate<float>;

libc/test/src/math/ldexp_test.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,6 @@
88

99
#include "LdExpTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/ldexp.h"
13-
#include "utils/CPP/Functional.h"
14-
#include "utils/FPUtil/FPBits.h"
15-
#include "utils/FPUtil/ManipulationFunctions.h"
16-
#include "utils/FPUtil/TestHelpers.h"
17-
#include "utils/UnitTest/Test.h"
18-
19-
#include <limits.h>
2012

2113
LIST_LDEXP_TESTS(double, __llvm_libc::ldexp)

libc/test/src/math/ldexpf_test.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,6 @@
88

99
#include "LdExpTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/ldexpf.h"
13-
#include "utils/CPP/Functional.h"
14-
#include "utils/FPUtil/FPBits.h"
15-
#include "utils/FPUtil/ManipulationFunctions.h"
16-
#include "utils/FPUtil/TestHelpers.h"
17-
#include "utils/UnitTest/Test.h"
18-
19-
#include <limits.h>
2012

2113
LIST_LDEXP_TESTS(float, __llvm_libc::ldexpf)

libc/test/src/math/ldexpl_test.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,6 @@
88

99
#include "LdExpTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/ldexpl.h"
13-
#include "utils/CPP/Functional.h"
14-
#include "utils/FPUtil/FPBits.h"
15-
#include "utils/FPUtil/ManipulationFunctions.h"
16-
#include "utils/FPUtil/TestHelpers.h"
17-
#include "utils/UnitTest/Test.h"
18-
19-
#include <limits.h>
2012

2113
LIST_LDEXP_TESTS(long double, __llvm_libc::ldexpl)

libc/test/src/math/llround_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "RoundToIntegerTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/llround.h"
1312

1413
LIST_ROUND_TO_INTEGER_TESTS(double, long long, __llvm_libc::llround)

libc/test/src/math/llroundf_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "RoundToIntegerTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/llroundf.h"
1312

1413
LIST_ROUND_TO_INTEGER_TESTS(float, long long, __llvm_libc::llroundf)

libc/test/src/math/llroundl_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "RoundToIntegerTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/llroundl.h"
1312

1413
LIST_ROUND_TO_INTEGER_TESTS(long double, long long, __llvm_libc::llroundl)

libc/test/src/math/lround_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "RoundToIntegerTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/lround.h"
1312

1413
LIST_ROUND_TO_INTEGER_TESTS(double, long, __llvm_libc::lround)

libc/test/src/math/lroundf_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "RoundToIntegerTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/lroundf.h"
1312

1413
LIST_ROUND_TO_INTEGER_TESTS(float, long, __llvm_libc::lroundf)

libc/test/src/math/lroundl_test.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
#include "RoundToIntegerTest.h"
1010

11-
#include "include/math.h"
1211
#include "src/math/lroundl.h"
1312

1413
LIST_ROUND_TO_INTEGER_TESTS(long double, long, __llvm_libc::lroundl)

libc/test/utils/FPUtil/x86_long_double_test.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,11 @@
66
//
77
//===----------------------------------------------------------------------===//
88

9-
#include "include/math.h"
109
#include "utils/FPUtil/FPBits.h"
1110
#include "utils/UnitTest/Test.h"
1211

12+
#include <math.h>
13+
1314
using FPBits = __llvm_libc::fputil::FPBits<long double>;
1415

1516
TEST(X86LongDoubleTest, isNaN) {

libc/utils/FPUtil/ManipulationFunctions.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
#include "NearestIntegerOperations.h"
1414
#include "NormalFloat.h"
1515

16-
#include "include/math.h"
1716
#include "utils/CPP/TypeTraits.h"
1817

1918
#include <limits.h>
19+
#include <math.h>
2020

2121
namespace __llvm_libc {
2222
namespace fputil {

0 commit comments

Comments
 (0)