Topic: templatized typedef?
Author: jnw@shades.cis.ufl.edu (Joseph N. Wilson)
Date: 22 Dec 92 20:45:07 GMT Raw View
Please forgive me if this is old ground for this group.
CFront 3.0.1 does not let me do the following:
template <class T>
class C{ ... };
template <class S>
typedef C<S> D;
The reason I'd like to do this is to be able to rename (using typedef)
a number of classes. I thought this would be a clean way to rename
the template classes if it were supported. I had a suspicion it might not
be supported right from the start.
Anyway, here's my question:
Is what I'm trying to do above _standard_ C++, or is it a fringe interpretation.
I figured because my typedef is a decl-specifier introducing a class-name,
that it should be a valid class declaration, thus the ARM should be satisfied
on page 342. Is my reasoning faulty? What do you gurus say?
Joe Wilson
(jnw@cis.ufl.edu)
P.S. CFront complains saying "D: only static data class members may be
parameterized." I have difficulty interpreting this message in the context
above.