This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/17555] function visibility attribute in definition misinterpreted
- From: "jsm at polyomino dot org dot uk" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Sep 2004 21:52:33 -0000
- Subject: [Bug c/17555] function visibility attribute in definition misinterpreted
- References: <20040918211626.17555.drepper@redhat.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From jsm at polyomino dot org dot uk 2004-09-18 21:52 -------
Subject: Re: New: function visibility attribute in definition
misinterpreted
On Sat, 18 Sep 2004, drepper at redhat dot com wrote:
> When a function visibility attribute is used in the definition of a function and
> the return value type of the function is a pointer, the attribute is
> misinterpreted as belonging to the type. Example:
This appears to be the same as bug 17251. The attribute in that position
syntactically applies to the return type, but there has traditionally been
a fair amount of flexibility in interpreting attributes in "wrong" places
sensibly - for example, applying attributes on a return type to the
declaration instead if they don't make sense on the return type. This is
what probably makes sense to do in this case.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17555