Bug #15914 Updated: *lots* of compiler warnings...

From: Date: Tue, 18 Jun 2002 10:35:10 +0000
Subject: Bug #15914 Updated: *lots* of compiler warnings...
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-11112@lists.php.net to get a copy of this message
ID: 15914 Updated by: derick@php.net Reported By: temp201@hotmail.com -Status: Open +Status: Bogus Bug Type: Compile Warning PHP Version: 4.1.2 Previous Comments: ------------------------------------------------------------------------ [2002-03-06 15:42:20] temp201@hotmail.com Compiler warnings ? You mean you want to see compiler warnings ? Well if youv'e got gcc, try compiling with -Wall -Wshadow -Wpointer-arith -Wcast-qual -W Just to give a few serious examples here: cast discards qualifiers from pointer target type comparison between signed and unsigned comparison of unsigned expression < 0 is always false signed and unsigned type in conditional expression declaration of `foo' shadows previous local declaration of `foo' shadows global declaration `foo' defined but not used implicit declaration of function `foo' left-hand operand of comma expression has no effect missing initializer passing arg 1 of `foo' discards qualifiers from pointer target type foo' declared bar' but never defined `register' is not at beginning of declaration statement with no effect `static' is not at beginning of declaration unused parameter `foo' Mind you, some of these, like "comparison between signed and unsigned" or "signed and unsigned type in conditional expression" are even considered FATAL or ILLEGAL by some compilers, instead of 'just' warnings... May I even dare suggest the developers (the ones using gcc at least) include the following: CFLAGS="-Wall -Wshadow -Wpointer-arith -Wcast-qual -W" CPPFLAGS="-Wall -Wshadow -Wpointer-arith -Wcast-qual -W" export CFLAGS CPPFLAGS to their .profiles ? ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=15914&edit=1

« previous php.bugs (#11112) next »