public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/54265] New: Documentation of "preferred attribute syntax for Types" contradicts examples in info.
@ 2012-08-14 23:05 rwhite at pobox dot com
  0 siblings, 0 replies; only message in thread
From: rwhite at pobox dot com @ 2012-08-14 23:05 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54265

             Bug #: 54265
           Summary: Documentation of "preferred attribute syntax for
                    Types" contradicts examples in info.
    Classification: Unclassified
           Product: gcc
           Version: 4.6.3
            Status: UNCONFIRMED
          Severity: trivial
          Priority: P3
         Component: other
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: rwhite@pobox.com


In the GCC info section 6.37 paragraph 4 reads:

[quote]For an enum, struct or union type, you may specify attributes either
between the enum, struct or union tag and the name of the type, or just
past the closing curly brace of the _definition_.  The former syntax is
preferred.[/quote]

This implies that the preferred syntax is:

struct __attribute__ ((aligned (8))) S { short f[3]; };

Unfortunately all of the examples in the remaining documentation are formatted
as the the allegedly inferior:

struct S { short f[3]; } __attribute__ ((aligned (8)));

So either the word "former" in paragraph 4 should be "latter" or all the
examples are given in the non-preferred syntax, which is confusing.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2012-08-14 23:05 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-14 23:05 [Bug other/54265] New: Documentation of "preferred attribute syntax for Types" contradicts examples in info rwhite at pobox dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).