from gcc -v gcc version egcs-2.91.66 Debian GNU/Linux (egcs-1.1.2 release)
toupper and tolower throw warnings (or not) depending on optimization. Compiling the following test program with: cc -Wall -ansi -pedantic -c junk.c will not give any errors. However, adding -O causes ansi warnings: cc -O -Wall -ansi -pedantic -c junk.c I expect to find these things in my code but not the system. It's not terribly important but it is irritating. I can turn off -ansi and -pedantic and it goes away but I loose the close checks. Is this a known problem? jim test prog... /* * test toupper and tolower with -ansi, et.al. */ #define _POSIX_SOURCE 1 #include <ctype.h> int main (void) { char c[] = "abc"; *c = toupper (*c); *c = tolower (*c); return 0; }