This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Const in default function arguments?
- From: Nathan Sidwell <nathan at codesourcery dot com>
- To: Eric Lemings <elemings at lemings dot com>
- Cc: eljay at adobe dot com, gcc-help at gcc dot gnu dot org
- Date: Sat, 05 Apr 2003 13:22:39 +0100
- Subject: Re: Const in default function arguments?
- Organization: Codesourcery LLC
- References: <200304051129.h35BTBGE001280@cyberia.lemings.com>
Eric Lemings wrote:
That's a bit different. The type of the default argument here
is T&. In the original post, the type is T.
ok,
class T {...};
void Baz (T = T ());
what's the problem? AFAICT, someone was making the blanket statement
that 'thou shall not have default values for non-constant argument
types'. such a statement is false.
nathan
--
Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
The voices in my head said this was stupid too
nathan at codesourcery dot com : http://www.cs.bris.ac.uk/~nathan/ : nathan at acm dot org