]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
doc: Document __attribute keyword [PR87591]
authorSandra Loosemore <sloosemore@baylibre.com>
Fri, 27 Feb 2026 03:46:27 +0000 (03:46 +0000)
committerSandra Loosemore <sloosemore@baylibre.com>
Sat, 28 Feb 2026 02:28:08 +0000 (02:28 +0000)
gcc/ChangeLog
PR c/87591
* doc/extend.texi (Attributes): Document __attribute keyword.
(Attribute Syntax): Here too.

gcc/doc/extend.texi

index ad20a3cbd3258682d011f9e411a18f2e27ef0612..ac9fb458f0b23b9b102060eb00bb45be51cfb972 100644 (file)
@@ -1777,6 +1777,9 @@ and suffixed by two underscores; for example, the alternate name of
 library header files in case they are included into files that have
 redefined the base name of the attribute as a preprocessor macro.
 
+GCC also accepts the keyword @code{__attribute} as a synonym for
+@code{__attribute__}.
+
 Some function attributes take one or more arguments that refer to
 the function's parameters by their positions within the function parameter
 list.  Such attribute arguments are referred to as @dfn{positional arguments}.
@@ -9859,6 +9862,8 @@ This allows you to use them in header files without
 being concerned about a possible macro of the same name.  For example,
 you may use the attribute name @code{__noreturn__} instead of @code{noreturn}.
 
+GCC also accepts the keyword @code{__attribute} as a synonym for
+@code{__attribute__}.
 
 @subsubheading Label Attributes