[libc-commits] [libc] [libc][NFC] clean up some includes (PR #99719)

Michael Jones via libc-commits libc-commits at lists.llvm.org
Fri Jul 19 16:39:39 PDT 2024


https://github.com/michaelrj-google created https://github.com/llvm/llvm-project/pull/99719

While looking through the list of includes for #99693 I found these
includes that also need to be cleaned up. I removed the extra includes
in expm1.cpp, but the include in thread.h needs more attention so I just
marked it with a todo.


>From 8c297858d036c4446bc36523136f9996ae2d9241 Mon Sep 17 00:00:00 2001
From: Michael Jones <michaelrj at google.com>
Date: Fri, 19 Jul 2024 16:36:04 -0700
Subject: [PATCH] [libc][NFC] clean up some includes

While looking through the list of includes for #99693 I found these
includes that also need to be cleaned up. I removed the extra includes
in expm1.cpp, but the include in thread.h needs more attention so I just
marked it with a todo.
---
 libc/src/__support/threads/thread.h | 1 +
 libc/src/math/generic/expm1.cpp     | 7 -------
 2 files changed, 1 insertion(+), 7 deletions(-)

diff --git a/libc/src/__support/threads/thread.h b/libc/src/__support/threads/thread.h
index ce23a880e048a..5950a4dfb3e53 100644
--- a/libc/src/__support/threads/thread.h
+++ b/libc/src/__support/threads/thread.h
@@ -17,6 +17,7 @@
 #include "src/__support/macros/config.h"
 #include "src/__support/macros/properties/architectures.h"
 
+// TODO: fix this unguarded linux dep
 #include <linux/param.h> // for exec_pagesize.
 
 #include <stddef.h> // For size_t
diff --git a/libc/src/math/generic/expm1.cpp b/libc/src/math/generic/expm1.cpp
index d9485864df899..a4dbf38ab27d0 100644
--- a/libc/src/math/generic/expm1.cpp
+++ b/libc/src/math/generic/expm1.cpp
@@ -30,13 +30,6 @@
 #define LIBC_MATH_EXPM1_SKIP_ACCURATE_PASS
 #endif
 
-// #define DEBUGDEBUG
-
-#ifdef DEBUGDEBUG
-#include <iomanip>
-#include <iostream>
-#endif
-
 namespace LIBC_NAMESPACE_DECL {
 
 using fputil::DoubleDouble;



More information about the libc-commits mailing list