Re: [PHP4BETA] cvs: php4 /ext/standard/ levenshtein.c

From: Date: Tue, 23 May 2000 21:46:02 +0000
Subject: Re: [PHP4BETA] cvs: php4 /ext/standard/ levenshtein.c
References: 1  Groups: php.version4 
Request: Send a blank email to php-version4+get-15609@lists.php.net to get a copy of this message
On Tue, 23 May 2000, Hartmut Holzgraefe wrote: > Zeev Suraski wrote: > > The problem with the 'dirty trick' is that sizeof(void *) isn't necessarily > > equal to sizeof(int). On many platforms it isn't. > > sure, i know that, but chances that a long is smaler than a pointer are > not > that bad,i even thought about protecting it with an assert() instead of > doing it right in the first place, stupid me ... There is no guarantee that casting a pointer to long and casting the result to a pointer will yield the original pointer. That means the code must not rely on this assumption, or it is considered broken. > but i never thought of this as a _compile_ time problem ... :( GCC is not the right tool for testing source code on conformance to existing standards. Most other compilers are stricter in one or another way. > PS: seems that cvs.php.net doesn't know about my new address > (hartmut@six.de instead of hholzgra@media-engieering.de) > could somebody change this or tell me where to ... ? I've changed it. - Sascha

« previous php.version4 (#15609) next »