+2017-01-26 Keith Marshall <keithmarshall@users.sourceforge.net>
+
+ Avoid #include_next misbehaviour; cf. MinGW-Bug [#2330]
+
+ * include/ctype.h (wctype.h): Use "..." form of #include, rather than
+ the <...> form; we must include our own corresponding mingwrt version
+ of this subsidiary header, and avoid any bogus alternative which may
+ have been insinuated earlier in the system header path.
+
+ * include/string.h (wchar.h): Likewise.
+
2017-01-25 Jason Hood <jadoxa@yahoo.com.au>
Correct quoted backslash handling, per bug [#2328].
* $Id$
*
* Written by Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
- * Copyright (C) 1997-2008, 2016, MinGW.org Project
+ * Copyright (C) 1997-2008, 2016, 2017, MinGW.org Project
*
*
* Permission is hereby granted, free of charge, to any person obtaining a
* properly declared here, this file should also declare elements of the
* wide classification API, which is properly declared in <wctype.h>
*
- * To avoid the burden of maintaining duplicate declarations, in two
+ * To avoid the burden of maintaining duplicate declarations in two
* locations, we keep the wide character declarations where ISO-C and
* POSIX say they belong, in <wctype.h>, while accommodating Microsoft
* compatibility by providing for selective inclusion of the relevant
* elements of it here. (Note that we must do this early, because to
* avoid duplication, we delegate the definition of common character
* classification macros, with the exception of _LEADBYTE, which is
- * not required in both headers, to <wctype.h>).
+ * not required in both headers, to <wctype.h>; we use the quoted
+ * form of inclusion here, to ensure that we get our own "wctype.h",
+ * and not any predecessor which may have been insinuated into the
+ * system include path, and which may interfere with our mechanism
+ * for partial inclusion of shared header content).
*/
#define __CTYPE_H_SOURCED__
-#include <wctype.h>
+#include "wctype.h"
/* This is the one character classification macro, for which definition
* is NOT delegated to <wctype.h>
* $Id$
*
* Written by Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
- * Copyright (C) 1997-2000, 2002-2004, 2007, 2009, 2015, 2016,
+ * Copyright (C) 1997-2000, 2002-2004, 2007, 2009, 2015-2017,
* MinGW.org Project.
*
*
* scope, will selectively expose the required function prototypes;
* however, strictly ISO-C conforming applications should include
* <wchar.h> directly; they should not rely on this MSVC specific
- * anomalous behaviour.
+ * anomalous behaviour. (We use the quoted form of inclusion here,
+ * to ensure that we get our own "wchar.h", and not any predecessor
+ * which may have been insinuated into the system include path, and
+ * so could interfere with our mechanism for partial inclusion of
+ * shared header content).
*/
-#include <wchar.h>
+#include "wchar.h"
#endif /* ! __STRICT_ANSI__ */