[Patch] Add C11 uchar/wchar related __STDC_* definitions
Ed Schouten
ed at 80386.nl
Sun May 26 03:52:18 PDT 2013
Hi Dmitri,
2013/5/25 Dmitri Gribenko <gribozavr at gmail.com>:
> Please add tests. (Tests for these macros should probably go into
> test/Preprocessor/init.c).
Added! (Please refresh)
http://80386.nl/pub/clang-c11-uchar.txt
> Should this be conditional on C11 or C++11?
Though these definitions are only part of C11/C++11, I think it would
be safer to just define them unconditionally. For example, a piece of
code assumes C11, but is not built with -std=c11, it may wrongly
assume !defined(__STDC_MB_MIGHT_NEQ_WC__), which could have disastrous
side-effects.
--
Ed Schouten <ed at 80386.nl>
More information about the cfe-commits
mailing list