Purpose: to eliminate some warnings in wchar.h under
GCC 2.95.x, like
c:/mingw/bin/../lib/gcc-lib/mingw32/2.95.3-
8/../../../../include/wchar.h:
In function `int fwide(FILE *, int)':
c:/mingw/bin/../lib/gcc-lib/mingw32/2.95.3-
8/../../../../include/wchar.h:301:
warning: unused parameter `struct FILE * stream'
c:/mingw/bin/../lib/gcc-lib/mingw32/2.95.3-
8/../../../../include/wchar.h:301:
warning: unused parameter `int mode'
c:/mingw/bin/../lib/gcc-lib/mingw32/2.95.3-
8/../../../../include/wchar.h:
In function `int mbsinit(const mbstate_t *)':
c:/mingw/bin/../lib/gcc-lib/mingw32/2.95.3-
8/../../../../include/wchar.h:302:
warning: unused parameter `const mbstate_t * ps'
It should also be OK to comment out the unused
arguments.
Patch to wchar.h
Logged In: YES
user_id=11494
With your patch:
D:\develop\cygwin-cvs-head\src\winsup\mingw\include>gcc -
c -x c wchar.h
wchar.h: In function `fwide':
wchar.h:301: error: parameter name omitted
wchar.h:301: error: parameter name omitted
wchar.h: In function `mbsinit':
wchar.h:302: error: parameter name omitted
Logged In: YES
user_id=399758
OK. C and C++ have different rules for arguments, which I did
not see. Changing the Makefile or tolerating the warning is
easier than trying to maintain different code for C and C++.
Logged In: YES
user_id=30442
Wu,
You already posted this patch to mingw-dvlpr and Danny
replied on 10 Feb describing the problem and a simple solution:
http://article.gmane.org/gmane.comp.gnu.mingw.devel/859
I'm just pointing it out because your submitting this patch
suggests that you probably missed his reply.
Luke