[LLVMbugs] [Bug 7955] New: Clang's stddef.h, wint_t and MinGW headers
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sat Aug 21 08:25:56 PDT 2010
http://llvm.org/bugs/show_bug.cgi?id=7955
Summary: Clang's stddef.h, wint_t and MinGW headers
Product: clang
Version: trunk
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P
Component: Headers
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: salvois at users.sourceforge.net
CC: llvmbugs at cs.uiuc.edu
Greetings,
in order to function properly with other MinGW headers, it should be possible
to include Clang's stddef.h more than once bypassing the __STDDEF_H include
guard.
For example stdio.h includes stddef.h with __need_wint_t to define wint_t, and
it may fail if stddef.h has been included before without __need_wint_t defined.
I've solved this issue by moving the whole block defining wint_t outside the
__STDDEF_H include guard. It should not have any side effects.
BTW, the comment "Some C libraries expect to see a wint_t here. Others (notably
MinGW) will use __WINT_TYPE__ directly" is misleading: at least the current
MinGW *does* expect wint_t in stddef.h.
Thanks,
Salvo
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list