This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Is This Really A Parse Error?
- To: Tom Larsen <tomar at eai dot com>
- Subject: Re: Is This Really A Parse Error?
- From: Alexandre Oliva <oliva at dcc dot unicamp dot br>
- Date: 22 Jul 1999 18:29:45 -0300
- Cc: gcc at egcs dot cygnus dot com
- References: <37963160.26B10BCE@eai.com>
On Jul 21, 1999, Tom Larsen <tomar@eai.com> wrote:
> static Hasher<V,K> hash(V(),K(),this); // error.
As Jason wrote, this is a bug in the compiler. A simpler work around
that usually works is to enclose the first argument within
parentheses:
static Hasher<V,K> hash((V()),K(),this);
This should be enough for g++ to tell `V()' is to be parsed as an
expression, not as a declaration of an anonymous argument.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
oliva@{dcc.unicamp.br,guarana.{org,com}} aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
** I may forward mail about projects to mailing lists; please use them