Ilia Alshanetsky wrote:
Andrey Hristov wrote:
Because both functions are in HEAD and still the API is not released
I would appreciate if time_nanosleep() is renamed to nanosleep().
time_sleep_until() "emulate" a system function but uses it and in this
case maybe the name may stay the same.
To rephrase, if there are no objections I will go and rename
time_nanosleep()
to nanosleep() :)
I'd prefer the function remain called time_nanosleep(), while there is
certainly a value to having C -> PHP mappings have the same name. The
direction we seem to be taking lately is towards "namespacing" similar
functions together.
Ilia
Hi Ilia,
indeed I have already mentioned the namespacing of core functions. However, I
cannot recall a case of a function that was added recently and which resembles
the
interface to the underlying C function to be named with having the namespacing
trend in mind. Maybe being consistent with our current trend is better than
confusing
the users. I would not like to read somewhere :
"PHP is inconsistent in parts of its API and even it happens to be inconsistent
while
trying to be consistent. One such case is the *sleep functions, where all but
one
are named after the corresponding C function but nanosleep is time_nanosleep()."
I wouldn't advocate such a change if the function was something which is
quasi-unique to PHP. With quasi-unique I mark that the function is not there to
give user an access to an already existing system function.
Andrey
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php