Compiler says cast then when done says no can do
Ty Tower
towerty at msn.com.au
Wed May 21 04:25:48 PDT 2008
I have this line
double balance=values[6]-values[5]; (values 5&6 are char[])
so I change to
double balance=-(double)values[6]-(double)values[5];
compiler says : C style cast illegal, use cast(double)values[6]
so I change to
double balance=cast(double)values[6]-cast(double)values[5];
compiler says: Error: e2ir: cannot cast from char[] to double
So as I see it the compiler message in this case at least is wrong or there is a problem casting from a char array to a double . Is it a problem with the compiler message?
More information about the Digitalmars-d-learn
mailing list