I thought you had these in already?
alias float[3] Vc3;
int main(char[][] args)
{
Vc3
a,b,c;
a[] = b[] +
c[];
return
0;
}
testvector.d(27): Array operations not implemented
And I will need to be able to initialize arrays with
array literals, such as:
float[3] up
= { 0, 1, 0 };
float[3] down =
{ 0,-1, 0 };
testvector.d(22): Error: a struct is not a valid initializer for a
float[3]
This initialization stuff is so fundamental
that I can't get far without it. It's very tedious to
write:
float[3]
up;
up[0] =
0;
up[1] =
1;
up[2] =
0;
And not only that but it's impossible to initialize global or static arrays
properly, at point of declaration; you have to do it inside a function like
main.
Vc3
a,b,c;
a[0] = b[0] +
c[0];
a[1] = b[1] +
c[1];
a[2] = b[2] + c[2];
return
0;
If I wanted to do that I would use C.
Bother.
Maybe I'll try overloading my own operators, see if that works
yet.
Sean