From 3421791193713671011
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,e7ce30bc16218953
X-Google-Attributes: gidf78e5,public
X-Google-ArrivalTime: 2003-01-08 10:02:40 PST
Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!cyclone.bc.net!snoopy.risq.qc.ca!newshub.northeast.verio.net!verio!kibo.news.demon.net!mutlu.news.demon.net!demon!mail2news.demon.co.uk!devnull
From: nesotto@cs.auc.dk ("THORSTEN OTTOSEN")
Newsgroups: comp.std.c++
Subject: Re: function template specialization deduction
Date: Wed, 8 Jan 2003 18:02:24 +0000 (UTC)
Organization: SunSITE.dk - Supporting Open Source Software
Lines: 31
Approved: fjh@cs.mu.oz.au (Fergus Henderson , moderator of comp.std.c++)
Message-ID: <avh1ge$cmr$1@sunsite.dk>
References: <avf2t8$krl$1@sunsite.dk> <g2dm1vs0itq0ur51qi1m9lbjumoda8rd7b@4ax.com>
X-Trace: mail2news.demon.co.uk 1042048945 20186 10.0.0.1 (8 Jan 2003 18:02:25 GMT)
X-Complaints-To: abuse@demon.net
NNTP-Posting-Date: Wed, 8 Jan 2003 18:02:25 +0000 (UTC)
X-Received: from mulga.cs.mu.oz.au ([128.250.1.22])
	by news.demon.co.uk with esmtp (Exim 4.05)
	id 18WKX1-0005FQ-00
	for mail2news@news.news.demon.net; Wed, 08 Jan 2003 18:02:23 +0000
X-Received: from localhost (localhost [[UNIX: localhost]]) by mulga.cs.mu.OZ.AU
	id EAA11607; Thu, 9 Jan 2003 04:43:13 +1100 (EST)
X-Authentication-Warning: mulga.cs.mu.OZ.AU: fjh set sender to devnull@stump.algebra.com using -f
X-Path: comp-std-cpp-robomod!not-for-mail
X-Robomod: STUMP, ichudov@algebra.com (Igor Chudov)
X-Delivered-To: std-c++@ncar.ucar.edu
X-Newsgroups: comp.std.c++
X-NNTP-Posting-Date: Wed, 8 Jan 2003 11:19:42 +0000 (UTC)
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-Authenticated: <anon>@<local>
X-Spam-Status: No, hits=-4.5 required=5.0
	tests=INVALID_MSGID,NOSPAM_INC,PRIORITY_NO_NAME,
	      QUOTED_EMAIL_TEXT,REFERENCES,SPAM_PHRASE_00_01
	version=2.41
Xref: archiver1.google.com comp.std.c++:16900

"Graeme Prentice" <gp1@paradise.net.nz> wrote in message
news:g2dm1vs0itq0ur51qi1m9lbjumoda8rd7b@4ax.com...

> Maybe you could define the stack version as
>
> template< typename A >
> inline void insert( std::stack<A>& c,  A const& v )
> {
>     c.push( v );
> }
>
> and only include it when you #include <stack> somehow, rather than
> depend on container_type not being present in other containers.

I just realized why it would not work that good: it would requre that users
include their headers in
a very strict ordering, eg., the stack header would have to be included
before
my header.

regards

Thorsten


---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.jamesd.demon.co.uk/csc/faq.html                       ]



