Alias Expressions
    Xinok 
    xinok at live.com
       
    Sun Apr 22 20:17:46 PDT 2012
    
    
  
I know this has probably been asked for a hundred times before, 
but I don't understand why D doesn't support this. Template alias 
parameters can accept nearly anything as an argument that 
standard aliases don't. I think standard aliases should be 
equally as powerful as their template counterpart.
If you can write this:
template Eval(alias arg){ alias arg Eval; }
alias Eval!(cond ? a : b) al;
Why not simply allow this?
alias (cond ? a : b) al;
Or perhaps this:
alias al = cond ? a : b;
    
    
More information about the Digitalmars-d
mailing list