From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13335 invoked by alias); 15 Nov 2002 16:06:07 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 13320 invoked by uid 71); 15 Nov 2002 16:06:06 -0000 Date: Thu, 21 Nov 2002 07:18:00 -0000 Message-ID: <20021115160606.13319.qmail@sources.redhat.com> To: nobody@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, From: Wolfgang Bangerth Subject: Re: c++/8567: std::endl is of unknown type when overloading operator<< (repeat in case attachment didnt work) Reply-To: Wolfgang Bangerth X-SW-Source: 2002-11/txt/msg00768.txt.bz2 List-Id: The following reply was made to PR c++/8567; it has been noted by GNATS. From: Wolfgang Bangerth To: Jason Stanek Cc: gcc-bugs@gcc.gnu.org, , Subject: Re: c++/8567: std::endl is of unknown type when overloading operator<< (repeat in case attachment didnt work) Date: Fri, 15 Nov 2002 10:06:47 -0600 (CST) > Isnt there a way to specify a default template type? > > So instead of declaring endl as a pure template, it has a default type in > the case that you dont specify one. > > Something like this: > > namespace std { > template T& endl (T&); > }; Default template arguments are only possible for classes, not for function templates. Regards Wolfgang ------------------------------------------------------------------------- Wolfgang Bangerth email: bangerth@ticam.utexas.edu www: http://www.ticam.utexas.edu/~bangerth