[libc-commits] [libc] c530dad - [libc] Remove unnecessary `stdio.h` includes (#98132)

via libc-commits libc-commits at lists.llvm.org
Tue Jul 9 05:08:30 PDT 2024


Author: Petr Hosek
Date: 2024-07-09T05:08:25-07:00
New Revision: c530dadebb2c4f073daac3f0ec61bd41fa7a367d

URL: https://github.com/llvm/llvm-project/commit/c530dadebb2c4f073daac3f0ec61bd41fa7a367d
DIFF: https://github.com/llvm/llvm-project/commit/c530dadebb2c4f073daac3f0ec61bd41fa7a367d.diff

LOG: [libc] Remove unnecessary `stdio.h` includes (#98132)

Added: 
    

Modified: 
    libc/src/stdio/baremetal/getchar.cpp
    libc/src/stdio/puts.h

Removed: 
    


################################################################################
diff  --git a/libc/src/stdio/baremetal/getchar.cpp b/libc/src/stdio/baremetal/getchar.cpp
index bbd5ba7a954fb..6398197e2f143 100644
--- a/libc/src/stdio/baremetal/getchar.cpp
+++ b/libc/src/stdio/baremetal/getchar.cpp
@@ -9,8 +9,6 @@
 #include "src/stdio/getchar.h"
 #include "src/__support/OSUtil/io.h"
 
-#include <stdio.h>
-
 namespace LIBC_NAMESPACE {
 
 LLVM_LIBC_FUNCTION(int, getchar, ()) {

diff  --git a/libc/src/stdio/puts.h b/libc/src/stdio/puts.h
index 11fbd0be897cf..68d5225b00a17 100644
--- a/libc/src/stdio/puts.h
+++ b/libc/src/stdio/puts.h
@@ -9,8 +9,6 @@
 #ifndef LLVM_LIBC_SRC_STDIO_PUTS_H
 #define LLVM_LIBC_SRC_STDIO_PUTS_H
 
-#include <stdio.h>
-
 namespace LIBC_NAMESPACE {
 
 int puts(const char *__restrict str);


        


More information about the libc-commits mailing list