[Insight-developers] itkVector initialization problem

Julien Jomier jjomier@cs.unc.edu
Thu, 7 Feb 2002 14:57:13 -0500


Hello,

I found a "bug" in itkVector when trying to initialize an itk vector 
with the first element equal to zero.

itk::Vector<double,3> myVector;
myVector = 0,1,2;

compiler returns the error :  'operator =' is ambiguous

Luis found that the problem is in  itkVector.h   line 186
There is a set of    operator=()     methods.
The one in line 104 expects an array (a C traditional array).
When this method is commented out, the compilation error
disappears.

It looks like we will have to chose between one or the other....
Remove one of them....or rename one of them and not
use it as an operator=()...

Any suggestions ?

Thanks

Julien