So, I'm still working on my matrix class (in case anyone reading this also read my thread from the other day). I really like the array-feature that I can initialize an array with a list of numbers, such as
double array[2]={1,2};
and would like to implement that in my matrix class as well. So far I have overloaded my operator= to accept an array of doubles, but that still means that I need to use two lines, first making an array, and then feeding it to my matrix. Does the {, , ,}-structure have a type?
In other words, what I have right now is
cMatrix& operator= (const double* array)
(with cMatrix being my matrix class). How should I change that definition to make it accept the {, , ,} directly?
Help will be much appreciated =)