This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix PR C++/9021 and 11005 -TAKE 2


Yes, that's fine as well.

--
Mark Mitchell
CodeSourcery, LLC
mark@codesourcery.com
----- Original Message ----- 
From: "Danny Smith" <danny_r_smith_2001@yahoo.co.nz>
To: "Mark Mitchell" <mark@codesourcery.com>
Cc: "Gabriel Dos Reis" <gdr@integrable-solutions.net>; "GCC Patches"
<gcc-patches@gcc.gnu.org>
Sent: Tuesday, January 13, 2004 6:37 PM
Subject: Re: [PATCH] Fix PR C++/9021 and 11005 -TAKE 2


> --- Mark Mitchell <mark@codesourcery.com> wrote: > On Thu, 2003-12-18 at
01:07, Danny Smith
> wrote:
> > >  --- Gabriel Dos Reis wrote:
> > > > More stringent:
> > > >
> > > >    (1) allow attributes only when defining the class;
> > >
> > > Hi,
> > >
> > > Documentation (extend.texi) states that type attributes are to be
specified on
> > > "@emph{definition}". This patch prevents the type attributes that were
> > > specified on definition from being overwitten in C++.
> > >
> > >
> > > Bootstrapped, regtested on i686-pc-mingw32.
> > >
> > > cp/ChangeLog
> > >
> > > 2003-12-18  Danny Smith  <dannysmith@users,sourceforge.net>
> > >
> > > PR c++/9021
> > >   PR c++/11005
> > > * parser.c (cp_parser_elaborated_type_specifier): Warn about
> > > attributes and discard.
> > > * decl.c (xref_tag): Don't overwrite existing attributes with
> > > NULL_TREE.
> >
> > OK.
>
>
> Hi,
>
> This patch to testsuite is also needed because of the new warnings.
>
> Is this also OK?
>
>
> Danny
>
> testsuite/ChangeLog
>
> 2004-01-14  Danny Smith  <dannysmith@users.sourceforge.net>
>
> * g++.dg/ext/attrib9.C: Add dg-warnings.
>
> Index: g++.dg/ext/attrib9.C
> ===================================================================
> RCS file: /cvs/gcc/gcc/gcc/testsuite/g++.dg/ext/attrib9.C,v
> retrieving revision 1.1
> diff -c -3 -p -r1.1 attrib9.C
> *** g++.dg/ext/attrib9.C 6 Dec 2003 06:53:02 -0000 1.1
> --- g++.dg/ext/attrib9.C 14 Jan 2004 02:29:48 -0000
> ***************
> *** 1,5 ****
> ! class __attribute__((unused)) C;
> ! struct __attribute__((unused)) S;
> ! union __attribute__((unused)) U;
>   enum e {};
> ! enum __attribute__((unused)) e;
> --- 1,5 ----
> ! class __attribute__((unused)) C; //  { dg-warning "type attributes" }
> ! struct __attribute__((unused)) S; //  { dg-warning "type attributes" }
> ! union __attribute__((unused)) U; //  { dg-warning "type attributes" }
>   enum e {};
> ! enum __attribute__((unused)) e; //  { dg-warning "type attributes" }
>
>
> http://personals.yahoo.com.au - Yahoo! Personals
> New people, new possibilities. FREE for a limited time.
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]