summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDong-hee Na <donghee.na@python.org>2021-10-16 22:22:51 +0900
committerDong-hee Na <donghee.na@python.org>2021-10-17 20:45:24 +0900
commit59734d6e319042d964c6d5038f2b8d5db8b50792 (patch)
tree85cb0e44da0ddc62a03ed0d1ac97c7c4483b341d
parent72d7ce953827fe08a56b8ea64092f208be6ffc5b (diff)
downloadlibexpat-git-59734d6e319042d964c6d5038f2b8d5db8b50792.tar.gz
Reorder the location of including expat_config.h
-rw-r--r--expat/lib/xmlparse.c8
-rw-r--r--expat/lib/xmlrole.c4
-rw-r--r--expat/lib/xmltok.c4
-rw-r--r--expat/tests/runtests.c4
-rw-r--r--expat/xmlwf/xmlfile.c4
5 files changed, 12 insertions, 12 deletions
diff --git a/expat/lib/xmlparse.c b/expat/lib/xmlparse.c
index 5ba56eae..f7511656 100644
--- a/expat/lib/xmlparse.c
+++ b/expat/lib/xmlparse.c
@@ -54,6 +54,10 @@
USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
+#define XML_BUILDING_EXPAT 1
+
+#include <expat_config.h>
+
#if ! defined(_GNU_SOURCE)
# define _GNU_SOURCE 1 /* syscall prototype */
#endif
@@ -84,14 +88,10 @@
# include <errno.h>
#endif
-#define XML_BUILDING_EXPAT 1
-
#ifdef _WIN32
# include "winconfig.h"
#endif
-#include <expat_config.h>
-
#include "ascii.h"
#include "expat.h"
#include "siphash.h"
diff --git a/expat/lib/xmlrole.c b/expat/lib/xmlrole.c
index 08173b0f..7e3ea6e0 100644
--- a/expat/lib/xmlrole.c
+++ b/expat/lib/xmlrole.c
@@ -37,14 +37,14 @@
USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
+#include <expat_config.h>
+
#include <stddef.h>
#ifdef _WIN32
# include "winconfig.h"
#endif
-#include <expat_config.h>
-
#include "expat_external.h"
#include "internal.h"
#include "xmlrole.h"
diff --git a/expat/lib/xmltok.c b/expat/lib/xmltok.c
index f2b6b406..dcc35dc6 100644
--- a/expat/lib/xmltok.c
+++ b/expat/lib/xmltok.c
@@ -42,6 +42,8 @@
USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
+#include <expat_config.h>
+
#include <stddef.h>
#include <string.h> /* memcpy */
#include <stdbool.h>
@@ -50,8 +52,6 @@
# include "winconfig.h"
#endif
-#include <expat_config.h>
-
#include "expat_external.h"
#include "internal.h"
#include "xmltok.h"
diff --git a/expat/tests/runtests.c b/expat/tests/runtests.c
index 45ba5d59..2bd89891 100644
--- a/expat/tests/runtests.c
+++ b/expat/tests/runtests.c
@@ -39,12 +39,12 @@
USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
+#include <expat_config.h>
+
#if defined(NDEBUG)
# undef NDEBUG /* because test suite relies on assert(...) at the moment */
#endif
-#include <expat_config.h>
-
#include <assert.h>
#include <stdlib.h>
#include <stdio.h>
diff --git a/expat/xmlwf/xmlfile.c b/expat/xmlwf/xmlfile.c
index 50d02f8f..f36c2995 100644
--- a/expat/xmlwf/xmlfile.c
+++ b/expat/xmlwf/xmlfile.c
@@ -36,6 +36,8 @@
USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
+#include <expat_config.h>
+
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
@@ -46,8 +48,6 @@
# include "winconfig.h"
#endif
-#include <expat_config.h>
-
#include "expat.h"
#include "internal.h" /* for UNUSED_P only */
#include "xmlfile.h"