summaryrefslogtreecommitdiff
path: root/giscanner/scannerlexer.l
diff options
context:
space:
mode:
authorChristoph Reiter <reiter.christoph@gmail.com>2019-01-01 18:06:47 +0100
committerChristoph Reiter <reiter.christoph@gmail.com>2019-01-01 18:06:47 +0100
commit295dcbd57c40d530abbc791cb5c1da15dea45d82 (patch)
treef9a9a85f30d23223fe2f6d5b3e36022c9dd49804 /giscanner/scannerlexer.l
parent0b09e4a142e81175bc56239c9ae80b5d5dfc6402 (diff)
downloadgobject-introspection-295dcbd57c40d530abbc791cb5c1da15dea45d82.tar.gz
ci: enable -Werror for msys2+meson
Diffstat (limited to 'giscanner/scannerlexer.l')
-rw-r--r--giscanner/scannerlexer.l15
1 files changed, 9 insertions, 6 deletions
diff --git a/giscanner/scannerlexer.l b/giscanner/scannerlexer.l
index 4d9657a6..bcce4397 100644
--- a/giscanner/scannerlexer.l
+++ b/giscanner/scannerlexer.l
@@ -371,6 +371,15 @@ check_identifier (GISourceScanner *scanner,
#define G_PATH_LENGTH 2048
#endif
+#ifdef _WIN32
+/* We don't want to include <windows.h> as it clashes horribly
+ * with token names from scannerparser.h. So just declare
+ * GetFullPathNameA() here unless we already defined it, like
+ * in giscanner.c.
+ */
+extern unsigned long __stdcall GetFullPathNameA(const char*, int, char*, char**);
+#endif
+
static inline char *
_realpath (const char *path)
{
@@ -379,12 +388,6 @@ _realpath (const char *path)
return realpath (path, buffer) ? g_strdup (buffer) : NULL;
#else
- /* We don't want to include <windows.h> as it clashes horribly
- * with token names from scannerparser.h. So just declare
- * GetFullPathNameA() here unless we already defined it, like
- * in giscanner.c.
- */
- extern unsigned long __stdcall GetFullPathNameA(const char*, int, char*, char**);
char *buffer;
char dummy;
int rc, len;