alias type reduction
    Philippe Sigaud 
    philippe.sigaud at gmail.com
       
    Thu Dec 13 14:15:51 PST 2012
    
    
  
> yeah, I tried that and got errors, I guess it works now. I still can't use
> the same class name as the alias though because I get a recursion error.
> It's not a huge deal but would be nicer to not have to mangle the class
> names to get it to work. The template stuff didn't work or I wasn't using
> it correctly.
>
What do you mean, 'mangle'? Using _ before the name?
It seems to me you can use the same name:
class A(T, bool condition)
{}
template A(T)
{
  alias A!(T, true) A;
}
void main()
{
    A!(int) a;
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d-learn/attachments/20121213/89b587ca/attachment.html>
    
    
More information about the Digitalmars-d-learn
mailing list