From 1895091376166654075
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,192ecde534e0a369
X-Google-Attributes: gidf78e5,public
From: clamage@Eng.Sun.COM (Steve Clamage)
Subject: Re: template members in non-template classes?
Date: 1995/06/04
Message-ID: <3qskvh$b7r@engnews2.Eng.Sun.COM>#1/1
X-Deja-AN: 103760126
references: <3qq7vi$esg@vishnu.jussieu.fr>
organization: Sun Microsystems Inc., Mountain View, CA
newsgroups: comp.std.c++

clerc@gla.ecoledoc.ibp.fr writes:

>In D&E, Stroustrup discusses template members
>using such an example (Shape class). The example
>uses a virtual template member. I take it from
>the WP that virtual template members are not allowed.

Correct. The compiler can't know when compiling the definition
what different instantiations of a virtual funciton
there will eventually be.

>But are template members in non-template classes allowed ?

Yes. But I don't know of any compilers that support it yet.


--
Steve Clamage, stephen.clamage@eng.sun.com



