]> granicus.if.org Git - clang/commitdiff
Updating documentation for the __has_attribute changes landed in r198897.
authorAaron Ballman <aaron@aaronballman.com>
Thu, 9 Jan 2014 23:11:13 +0000 (23:11 +0000)
committerAaron Ballman <aaron@aaronballman.com>
Thu, 9 Jan 2014 23:11:13 +0000 (23:11 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@198899 91177308-0d34-0410-b5e6-96231b3b80d8

docs/LanguageExtensions.rst
docs/ReleaseNotes.rst

index 7a4b31e7acc09b9a475e2dd91e69b26a19ccc7db..3ad078a5feeeb59cb58c6bda0ce0e148491fe5ee 100644 (file)
@@ -113,8 +113,8 @@ of ``cxx_rvalue_references``.
 -------------------
 
 This function-like macro takes a single identifier argument that is the name of
-an attribute.  It evaluates to 1 if the attribute is supported or 0 if not.  It
-can be used like this:
+an attribute.  It evaluates to 1 if the attribute is supported by the current
+compilation target, or 0 if not.  It can be used like this:
 
 .. code-block:: c++
 
@@ -134,6 +134,7 @@ The attribute name can also be specified with a preceding and following ``__``
 (double underscore) to avoid interference from a macro with the same name.  For
 instance, ``__always_inline__`` can be used instead of ``always_inline``.
 
+
 Include File Checking Macros
 ============================
 
index 07661a8803c28ca48d91d4d82dff95f0cacd95a7..12194f0d7abf255df1eb84b664f17fe4f442613e 100644 (file)
@@ -51,6 +51,11 @@ Major New Features
 GCC 4.7 changed the mingw ABI. Clang 3.4 and older use the GCC 4.6
 ABI. Clang 3.5 and newer use the GCC 4.7 abi.
 
+- The __has_attribute feature test is now target-aware. Older versions of Clang 
+would return true when the attribute spelling was known, regardless of whether 
+the attribute was available to the specific target. Clang now returns true only 
+when the attribute pertains to the current compilation target.
+
 
 Improvements to Clang's diagnostics
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^