Arrays

Patrick spam at spam.at
Sat Mar 17 01:58:54 PDT 2007


Thanks! I was just now thinking about that.

Jarrett Billingsley Wrote:

> "Patrick" <spam at spam.at> wrote in message 
> news:etevk0$1cu6$1 at digitalmars.com...
> >A struct which only contains one array of floats:
> > struct Vector {
> >   float[3] containingElements;
> > }
> > I may be too finicky but it really seems like codebloat to me. But if 
> > there arent any other solutions...
> 
> If it makes you feel any better, that won't change the size or behavior of 
> the vector at all.  It'll still be 12 bytes and passed by value.  But the 
> nice thing is that you can then add methods to the vector struct.  :\ 
> 
> 



More information about the Digitalmars-d-learn mailing list