This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
GCC 2.95 and ISO/IEC 9899 Amm 1 functions?
- From: "loresayer" <loresayer at msn dot com>
- To: <gcc-help at gcc dot gnu dot org>
- Date: Tue, 28 May 2002 01:28:59 -0400
- Subject: GCC 2.95 and ISO/IEC 9899 Amm 1 functions?
Morning all,
I was compiling a program earlier that uses
two (supposedly ISO/ANSI standard) C functions:
fwprintf( ) and wcsncpy( ). Surprisingly, these
were reported during compilation as implicitly
declared (ie, returning int and taking no
arguments).
Checking stdio.h (and wchar.h) in my includes
folder, I noticed these methods were not proto-
typed. Hence, it's correct that they're implicit-
ly declared because they weren't declared in
stdio.h and wchar.h (which I included), but now
I'm looking for where these function declarations
are located? I grepped whole subtrees to no
avail ...
I'm using GCC 2.95.3-5 on CygWin (it's library
(C run-time?) is /usr/lib/gcc-lib/i686-pc-cygwin
/2.95.3-5/libgcc.a). I'm uncertain if the include
headers were installed by GCC or CygWin, but as
the library's directory appears GCC-specific, I
thought I'd ask here first.
According to ISO/IEC 9899 Ammendment 1 (E?
dated 1995) fwprintf( ) and wcsncpy( ) are ISO
Standard C functions.
By extension, they are also two of the 209 ISO C
functions ANSI C++ includes (they are both named
in a draft list I found from 1996). I checked
<cstdio>, but (at least in 2.95.3-5) that's just
a wrapper around the stdio.h that doesn't have
fwprintf().
My original ref that these were ANSI functions
was MSDN documentation, so I did that extra bit of
background investigation, and sure enough, looks
like they should be.
On a broader note, the headers appear to be missing
a number of other ISO/IEC 9899 Ammendment 1 E
functions.
So my question is where are they? Was there some
reason they were left out? Have these methods
been added to a newer (stable) version of GCC?
Is this instead an issue with CygWin's headers?
Thanks for your pointers (I'll dereference them
provided they aren't NULL ;-) ),
Derek Harmon