[cfe-commits] [libc++] Switching to 'double underscore' notation for has_feature.

Jean-Daniel Dupas devlists at shadowlab.org
Thu Mar 1 10:18:08 PST 2012


Hi,

clang recently gained support for double underscore variant of the features in __has_feature test (the same way attributes support a double underscore variant).
This change provide a way to safely use __has_feature in system headers without conflicting with potential user defined macros.

As libc++ headers are system headers, I suggest we switch to using the double underscore variant. 
A problem I see is that applying this change will break compatibility with older clang version. 
If this is not an issue, I attached a patch that performs this change.

Thanks

-- Jean-Daniel



-------------- next part --------------
A non-text attachment was scrubbed...
Name: underscore.patch
Type: application/octet-stream
Size: 23953 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120301/3ea40e69/attachment.obj>


More information about the cfe-commits mailing list