This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: template typedef
- From: Vincent Torri <Vincent dot Torri at iecn dot u-nancy dot fr>
- To: gcc-help at gcc dot gnu dot org
- Date: Fri, 16 Dec 2005 14:09:10 +0100 (CET)
- Subject: Re: template typedef
- References: <BFC81524.6867%eljay@adobe.com>
Hey, thanks for the (2) answer(s)
ok, so its uses is a bit less obvious. You use the fact that classes can
be "templated" and that they can contain typedef.
just for curiosity, will the syntax that i have proposed will be in a
future standard (I've read that on google once) ?
Vincent Torri
On Fri, 16 Dec 2005, John Love-Jensen wrote:
> Hi Vincent,
>
> Yes, GCC 3.x and 4.x support template typedef. But not in the syntax of
> your example, rather it is support in a C++ (ISO 14882) compliant syntax.
>
> For example:
> template <typename T>
> struct Foo
> {
> typedef std::map<std::string, T> Registry;
> };
>
> HTH,
> --Eljay
>
>