I really doubt this will change.
It would be a *huge* mess in the docs
and peoples scripts and brains
if we did change it--it wouldn't really
win anyone anything:
At the risk of someone taking this as a worthwhile idea:
PHP_FUNCTION(strpos)
{
...
/* Swap needle and haystack if they appear to be backwards */
if (needle_len > haystack_len) {
char *t; int t_len;
t = needle; needle = haystack; haystack = t;
t_len = needle_len; needle_len = haystack_len; haystack_len = t_len;
}
...
}
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php