On Sun, Feb 10, 2002 at 12:20:55PM +0100, Sebastian Bergmann wrote:
> "Stig S. Bakken" wrote:
> > Well, shouldn't Mark, who maintains the code in question, be the one to
> > decide whether a couple of extra ifdefs makes his code unmaintainable?
> 
>   Well, needs msession a ''prime time seat'' in /php4/ext/, or wouldn't
>   we all be better off putting it into /pear/?

I certainly are one of those that don't like ifdefs. It's a bad sign
and it's difficult to test - read - the code. Having said that, msession
have few ifdefs compared to many other modules. We could throw
mysql and gd away  - they have more ifdefs! (pear is not a garbage can.
If it is treated as such, nobody will move).

What is interesting is that GD tops. I love GD but is one of the
nastiest modules to ./configure.

Actually a few ifdefs that reflect the changes in Zend is not that bad (what
is bad is the change of the interface). At least the #ifdefs force programmers' to
watch out! Furthermore, code that do have ifdefs is easier to move to pear.
As for the documentation it's the same story. If an interface changes over
time AND that is reflected in the code (because of ifdefs) they know that
this interface have changed between PHP versions.

For code that is going to stay within ext I think we should *allow* for
ifdefs that make the code work with at least the previous stable
version. The obvious good reason is testing. For example if somebody
breaks apache apxs (which did happen), it's good that I can test code
with the previous releasee to be able to continue coding on the module.

-- Adam

> 
> -- 
>   Sebastian Bergmann
>   http://sebastian-bergmann.de/                 http://phpOpenTracker.de/
> 
>   Did I help you? Consider a gift: http://wishlist.sebastian-bergmann.de/
> 
> -- 
> PHP Development Mailing List <http://www.php.net/>
> To unsubscribe, visit: http://www.php.net/unsub.php

-- 
Adam Dickmeiss  mailto:[EMAIL PROTECTED]  http://www.indexdata.dk
Index Data      T: +45 33410100           Mob.: 212 212 66

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to