Syntax for Attribute Specifications

The syntax for an attribute specification is

  __attribute__((list-of-attributes))  

where list-of-attributes is a comma-separated list of zero or more attributes to associate with the object. Place an attribute specification at the end of the declaration and definition of a function, function parameter, or variable. The following listing shows an example.

Listing: Example of an attribute specification
int f(int x __attribute__((unused))) __attribute__((never_inline));
int f(int x __attribute__((unused))) __attribute__((never_inline))

{

   return 20;

}