This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Proto-patch for "%I64" on Microsoft
On Fri, 26 Nov 2004, Mark Mitchell wrote:
> I don't know. Windows does not support "%ll" at all, so I'm not quite clear
> on what you're asking. Windows has no equivalent of /usr/include, so there
> are probably multiple inttypes.h implementations for Windows. There's the one
> provided by MinGW, at least. Microsoft Visual Studio may provide one too, but
> I'm not sure. The MinGW version does not use "%ll", but does use "%I64".
My point is that there are two separate questions: do we support user code
using "%I64" directly, and do we support user code using inttypes.h? If
inttypes.h uses %I64 and Windows doesn't support %ll at all, there's no
choice of doing just one, but it would be possible for some system to
support both %ll and %I64, and use %I64 in inttypes.h, in which case on
that system we'd have the opportunity to fix inttypes.h to work with
-std=c99 -pedantic -Wformat.
Actually fixing/replacing printf to support %ll is clearly too far to go
in fixing a defective C library, though we do provide the mem* functions
in libgcc on a few platforms that formerly didn't define
TARGET_MEM_FUNCTIONS and there's been discussion of doing much the same
with the float versions of <math.h> functions to avoid libstdc++-v3 and
libgfortran both needing to work around pre-C99 libraries which lack those
functions.
--
Joseph S. Myers http://www.srcf.ucam.org/~jsm28/gcc/
jsm@polyomino.org.uk (personal mail)
joseph@codesourcery.com (CodeSourcery mail)
jsm28@gcc.gnu.org (Bugzilla assignments and CCs)