This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libfortran/47945] REAL(8) output conversion error on MinGW32


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47945

--- Comment #11 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-03-02 17:03:47 UTC ---
(In reply to comment #9)
> It seems that MinGW has its own implementation of snprintf called
> __mingw_snprintf which can be activated by defining __USE_MINGW_ANSI_STDIO

In MinGW64, __USE_MINGW_ANSI_STDIO is set when _POSIX is specified. In MinGW
that does not seem to be the case and one needs to specify it either directly
or use another define such as _POSIX_SOURCE. Cf.
http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/mingw/include/_mingw.h?rev=1.61&cvsroot=src

>From libgfortran/libgfortran.h:

#if defined __MINGW32__
#  define _POSIX 1
#  define gfc_printf gnu_printf
#else


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]