Re: user defined vs php provided function (was Re: str_ireplace vs. stri_replace)
| From: | Tamas Arpad | Date: | Fri, 31 Jan 2003 11:14:48 +0000 |
| Subject: | Re: user defined vs php provided function (was Re: str_ireplace vs. stri_replace) | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-93842@lists.php.net to get a copy of this message | ||
> You are correct in the event of a user writing a new function, however
> consider what will happen if we are dealing with a old code, especially if
> it is no longer used just by the author but rather by a variety of other
> people not familiar with PHP code. The result is that after they or their
> ISPs upgrade to new PHP their scripts will stop working.
Couldn't it be solved with just a warning when a function is defined also in
user level space and use the user-defined function instead of the one
provided by php? Then old systems could work fine, and also the author could
notice that a new function is added to php with the same name.
I had the same problem before with array_search and was a real pain updating
all the sites and sending patches to customers after they installed new
version php.
Just an idea...
Arpi