commit 713f04313eb418a966bbc220aaade3e87daffadb
parent c6ad4b8aa10e59b7125daa1c42c84754350cf54b
Author: Frederic Cambus <fred@statdns.com>
Date: Fri, 23 Nov 2018 17:15:31 +0100
Run include-what-you-use to add missing headers and remove unnecessary ones
Diffstat:
6 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/TODO b/TODO
@@ -1,3 +1,2 @@
- Import documentation from Ansilove/PHP
- Display mode information in summary, and DOS aspect if enabled
-- Use include-what-you-use to remove unnecessary headers
diff --git a/src/main.c b/src/main.c
@@ -14,6 +14,7 @@
#include <err.h>
#include <getopt.h>
#include <stdbool.h>
+#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/src/sauce.c b/src/sauce.c
@@ -9,6 +9,9 @@
// See the LICENSE file for details.
//
+#include <stdlib.h>
+#include <string.h>
+
#include "sauce.h"
// Reads SAUCE via a filename.
diff --git a/src/sauce.h b/src/sauce.h
@@ -10,10 +10,8 @@
//
#define _XOPEN_SOURCE 700
-#include <stdint.h>
+#include <sys/types.h>
#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
#ifndef sauce_h
#define sauce_h
diff --git a/src/strtolower.c b/src/strtolower.c
@@ -9,6 +9,7 @@
// See the LICENSE file for details.
//
+#include <ctype.h>
#include "strtolower.h"
char *
diff --git a/src/strtolower.h b/src/strtolower.h
@@ -9,10 +9,6 @@
// See the LICENSE file for details.
//
-#include <ctype.h>
-#include <stdio.h>
-#include <stdlib.h>
-
#ifndef strtolower_h
#define strtolower_h