richard@deodand:~$ cat -n t.c 1 static int x(char *f) { 2 return *f; 3 } 4 5 int y(char *f) { 6 return *f; 7 } 8 9 void z(const char *g) { 10 int a; 11 a = x((char *)g); 12 a = y((char *)g); 13 } richard@deodand:~$ gcc-4.1 -Wall -O2 -c t.c richard@deodand:~$ gcc-4.2 -Wall -O0 -c t.c richard@deodand:~$ gcc-4.2 -Wall -O1 -c t.c t.c: In function 'z': t.c:11: warning: passing argument 1 of 'x' discards qualifiers from pointer target type richard@deodand:~$ gcc-4.1 --version gcc-4.1 (GCC) 4.1.3 20071019 (prerelease) (Debian 4.1.2-17) Copyright (C) 2006 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. richard@deodand:~$ gcc-4.2 --version gcc-4.2 (GCC) 4.2.3 20071014 (prerelease) (Debian 4.2.2-3) Copyright (C) 2007 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. richard@deodand:~$ dpkg -l gcc-4.{1,2} Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Installed/Config-files/Unpacked/Failed-config/Half-installed |/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad) ||/ Name Version Description +++-==============-==============-============================================ ii gcc-4.1 4.1.2-17 The GNU C compiler ii gcc-4.2 4.2.2-3 The GNU C compiler