I'm getting a strange compiler error. My code (located in a header file) is as follows:
static const double myDouble= 6.9;
static const int myInt= 6;
I get the compiler error "Illegal constant expression" on the line "static const double myDouble= 6.9;", but not on the line with " static const int myInt= 6;". In fact, the compiler gives that error for all doubles, but integers, shorts, and bools seem to be fine
Any help would be appreciated.
Message Edited by nbonwit on 2008-04-07 06:32 AM