PHP 4.0 Bug #8076: Array === argv
| From: | anthony at trams dot com | Date: | Sat, 02 Dec 2000 06:23:45 +0000 |
| Subject: | PHP 4.0 Bug #8076: Array === argv | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-39824@lists.php.net to get a copy of this message | ||
From: anthony@trams.com
Operating system: Win2k
PHP version: 4.0.3pl1
PHP Bug Type: Feature/Change Request
Bug description: Array === argv
In perl, I am able to pass an array to a function. When doing so, each of the array's indices
apear to be scalar values to the function.
When passing the equivalent form of an assicitave array to perl (hash array), the values passed to
the function apear to alternate between keys and values.
I am looking for this functionality in PHP, but must resort to constructing an eval() statement
instead.
So what I'm suggesting is a language construct, perhaps as follows:
array_as_argv() - which would alternate between keys and values.
array_keys_as_argv() - which would only pass the keys
array_values_as_argv() - which would only pass the values
This makes me think there might be a need for obj_as_argv(), but who knows?
See Bug id #5350
--
Edit Bug report at: http://bugs.php.net/?id=8076&edit=1