public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: "Pop Sébastian" <pop@gauvain.u-strasbg.fr>
To: nobody@gcc.gnu.org
Cc: gcc-prs@gcc.gnu.org,
Subject: Re: c++/7721: Very simple (but incorrect) template chokes g++
Date: Sun, 29 Sep 2002 03:46:00 -0000	[thread overview]
Message-ID: <20020929104601.10523.qmail@sources.redhat.com> (raw)

The following reply was made to PR c++/7721; it has been noted by GNATS.

From: =?iso-8859-1?Q?Pop_S=E9bastian?= <pop@gauvain.u-strasbg.fr>
To: nathan@gcc.gnu.org, gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org,
	johnc@parore.tait.co.nz, nobody@gcc.gnu.org, gcc-gnats@gcc.gnu.org
Cc: gdr@integrable-solutions.net
Subject: Re: c++/7721: Very simple (but incorrect) template chokes g++
Date: Sun, 29 Sep 2002 12:38:38 +0200

 On Fri, Sep 13, 2002 at 09:27:23PM -0000, nathan@gcc.gnu.org wrote:
 > Synopsis: Very simple (but incorrect) template chokes g++
 > 
 > State-Changed-From-To: open->analyzed
 > State-Changed-By: nathan
 > State-Changed-When: Fri Sep 13 14:27:23 2002
 > State-Changed-Why:
 >     confirmed as a regression
 > 
 > http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=7721
 
 
 Tested with 3 different versions of gcc:
 
 seb@myp233:~/test/cp$ gcc-2.95 -v
 Reading specs from /usr/lib/gcc-lib/i386-linux/2.95.4/specs
 gcc version 2.95.4 20011002 (Debian prerelease)
 
 seb@myp233:~/test/cp$ gcc-3.0 -v
 Reading specs from /usr/lib/gcc-lib/i386-linux/3.0.4/specs
 Configured with: ../src/configure -v --enable-languages=c,c++,java,f77,objc --prefix=/usr --infodir=/share/info --mandir=/share/man --enable-shared --with-gnu-as --with-gnu-ld --with-system-zlib --enable-long-long --enable-nls --without-included-gettext --disable-checking --enable-threads=posix --enable-java-gc=boehm --with-cpp-install-dir=bin --enable-objc-gc i386-linux
 Thread model: posix
 gcc version 3.0.4
 
 seb@myp233:~/test/cp$ gcc-3.2 -v
 Reading specs from /usr/lib/gcc-lib/i386-linux/3.2.1/specs
 Configured with: /mnt/data/gcc-3.1/gcc-3.2-3.2.1ds2/src/configure -v --enable-languages=c,c++,java,f77,proto,objc,ada --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-gxx-include-dir=/usr/include/c++/3.2 --enable-shared --with-system-zlib --enable-nls --without-included-gettext --enable-java-gc=boehm --enable-objc-gc i386-linux
 Thread model: posix
 gcc version 3.2.1 20020924 (Debian prerelease)
 
 
 Tested code:
 
 seb@myp233:~/test/cp$ cat pr7721.cc 
 template <class ForwardingPolicy > 
 class CallStrategy::CallStrategy()
  
 
 Results are:
 
 seb@myp233:~/test/cp$ gcc-2.95 -c pr7721.cc
 pr7721.cc:2: parse error before `('
 
 seb@myp233:~/test/cp$ gcc-3.0 -c pr7721.cc
 pr7721.cc:4: `template<ForwardingPolicy> class CallStrategy' as declarator 
    (compiler error)
 pr7721.cc:4: syntax error at end of input
 
 seb@myp233:~/test/cp$ gcc-3.2 -c pr7721.cc
 pr7721.cc:4: `template<class ForwardingPolicy> struct CallStrategy' as 
    declarator
 Please submit a full bug report,
 with preprocessed source if appropriate.
 See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.
 seb@myp233:~/test/cp$ 
 
 
 The problem is in  cp/decl.c: grokdeclarator ()
 
 case TEMPLATE_DECL is missing in the switch, making the function to give up 
 on the default case label:
 
           default:
 =>          my_friendly_assert (0, 20020917);
 
 
 Previous version of this code was:
 
  	  default:
 -	    cp_compiler_error ("`%D' as declarator", decl);
 -	    return 0; /* We used to do a 155 abort here.  */
 +	    my_friendly_assert (0, 20020917);
 
 
 Maybe we could give a better diagnostic for this error...
 Gaby, can you help to fix this error?
 
 
 Thanks,
 Sebastian


             reply	other threads:[~2002-09-29 10:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-09-29  3:46 Pop Sébastian [this message]
  -- strict thread matches above, loose matches on Subject: below --
2002-10-11 11:28 gdr
2002-10-08 15:36 Pop Sébastian
2002-09-29  7:46 Gabriel Dos Reis
2002-09-13 14:27 nathan
2002-08-26  1:46 John Carter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020929104601.10523.qmail@sources.redhat.com \
    --to=pop@gauvain.u-strasbg.fr \
    --cc=gcc-prs@gcc.gnu.org \
    --cc=nobody@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).