[cfe-commits] [Review request][PR7955] Fix wint_t stuff on stddef.h or cygming

NAKAMURA Takumi geek4civic at gmail.com
Mon Oct 18 20:47:04 PDT 2010


Applied in r116794, thank you!

...Takumi

2010/10/18 Douglas Gregor <dgregor at apple.com>:
>
> On Oct 13, 2010, at 6:15 PM, NAKAMURA Takumi wrote:
>
>> I had missed __WINT_TYPE__ is predefined also on cygming.
>>
>> An alternative patch is attached.
>>
>>> wint_t should be defined whenever <stddef.h> is included with __need_wint_t,
>>> and stddef.h should provide wint_t, on cygming.
>>
>> I think it would be essential, though, I am not special of C standards.
>
> Looks good; please go ahead and commit.
>
>        - Doug
>
>> ..Takumi
>>
>> /* for example */
>> #ifndef __WINT_TYPE__
>> #error
>> #endif
>>
>> #include <stddef.h>
>>
>> /* wint_t should not be available here */
>>
>> #define __need_wint_t
>> #include <stddef.h>
>>
>> /* wint_t should be available here */
>> wint_t *foo = (__WINT_TYPE__ *)0xDEADBEEF;
>>
>> #ifdef __need_wint_t
>> #error
>> #endif
>>
>> /* It should be able to request wint_t again */
>> #define __need_wint_t
>> #include <stddef.h>
>>
>>
>>
>> 2010/10/11 NAKAMURA Takumi <geek4civic at gmail.com>:
>>> Good midnight guys!
>>>
>>> I will post patches for cygwin and mingw. I think they would be
>>> essential to selfbuild clang on cygming.
>>>
>>> wint_t should be defined whenever <stddef.h> is included with __need_wint_t,
>>> and stddef.h should provide wint_t, on cygming.
>>>
>>>
>>> ...Takumi
>>>
>> <stddef_h_wint_t.diff.txt>_______________________________________________
>> cfe-commits mailing list
>> cfe-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
>
>




More information about the cfe-commits mailing list