K
keith
I have always been perfectly comfortable passing a string literal to a
function which expects either a 'char*' or a 'const char *', both in C
and C++, and I've never seen any warning about this, until today when
I built my library on a Solaris machine, the Sun CC compiler gives me:
Warning: String literal converted to char* in formal argument fmt in
call to LOG:rint
Can someone enlighten me why this compiler (version string "CC: Sun C+
+ 5.5 2003/03/12") thinks there may be something wrong with that?
function which expects either a 'char*' or a 'const char *', both in C
and C++, and I've never seen any warning about this, until today when
I built my library on a Solaris machine, the Sun CC compiler gives me:
Warning: String literal converted to char* in formal argument fmt in
call to LOG:rint
Can someone enlighten me why this compiler (version string "CC: Sun C+
+ 5.5 2003/03/12") thinks there may be something wrong with that?