Andy,
There is absolutely nothing wrong with trying to make the code more
maintainable, in fact I think everyone, myself included welcome any
work in that direction. But at the same time we need to keep in mind
that compiler is not always right and often will generate meaningless
warnings even when there is absolutely nothing wrong the code. Changes
for the sake of making the compiler happy with -Winsane-warnings ;-)
does not really help maintainability. In the case of {0} vs {NULL,
0,0}, my opinion is that the former is far more readable and
understandable.
On 27-Nov-07, at 10:50 AM, Andy Lester wrote:
On Nov 27, 2007, at 9:49 AM, Ilia Alshanetsky wrote:
GCC will spue a slew of warnings that can be safely ignored and in
some cases are bogus. The pedantic changes only make the code
harder to read and yield very little if any benefits in return. For
larger, more complex structs like zvals it'll only create a
meaningless mess. There is absolutely no reason that any half
decent compiler will not be able to understand {0} for any declared
struct.
My goal here is to improve long-term maintainability of the code, by
letting compilers and tools like splint do their automated magic
where possible. If this is not useful to the PHP core team, then
that's fine, I'll walk away. Let me know either way.
xoa
--
Andy Lester => [EMAIL PROTECTED] => www.petdance.com => AIM:petdance
Ilia Alshanetsky
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php