Wrote a blog post about CTFE and D

Danny Arends Danny.Arends at gmail.com
Thu Aug 30 04:52:37 PDT 2012


Thanks for the feedback, I'll update it..

I was thinking to remove the struct all together, but when doing 
the rotation matrices its actually more clean / useful to have 
structures.

Danny Arends
http://www.dannyarends.nl

On Thursday, 30 August 2012 at 11:25:55 UTC, bearophile wrote:
> Danny Arends:
>
>> http://www.dannyarends.nl/index.cgi?viewDetailed=00029
>
>
> struct Coord(T : float){
>   T[] d = [1.0, 0.0];
>
>
> Maybe better ==>
>
>
> struct Coord(T) if (isFloatingPoint!T) {
>     T[2] d = [1.0, 0.0];
>
>
> (isFloatingPoint is in std.traits)
>
> Bye,
> bearophile




More information about the Digitalmars-d-announce mailing list