Array of templated classes
Wyverex
wyverex.cypher at gmail.com
Mon Aug 18 15:52:26 PDT 2008
tsalm wrote:
> Hello,
>
> Does somebody know or have a way to do this :
>
> /* --- BEGIN ---*/
> class MyClass(T) {T myData;}
>
> void main()
> {
> MyClass[] myArray;
> }
>
> /* --- END --- */
>
> Thanks in advance for your help.
> TSalm
Not sure what version of D your using but D2.0 has a variant type..
http://www.digitalmars.com/d/2.0/phobos/std_variant.html
and so does tango
http://dsource.org/projects/tango/docs/current/tango.core.Variant.html
More information about the Digitalmars-d-learn
mailing list