# [PATCH] array_fill_keys

- Thread: https://externals.io/message/24375
- Original archive: https://news-web.php.net/php.internals/24375
- Started by Matt W on 2006-07-14T10:36:56+00:00
- Messages: 1
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #24375 — Matt W — 2006-07-14T10:36:56+00:00

URL: https://externals.io/message/24375#24375

Hi,

Here's a patch to add the `array_fill_keys()` function instead of extending
 `array_fill()`.  I left the bit of cleanup/tweaks I had done to array_fill.
Can someone please review and let me know if anything needs changing?

I have a feeling something will still be wrong it -- works fine, but with
recent code changes, it looks like you're switching to
zend_parse_parameters() where ...get_parameters_ex() had been used.  Of
course I used get_parameters, following array_fill.  So do I need to change
it, and is that only for MAIN branch?  Also wasn't sure if I should mark the
new function "U"nicode compatible.

I'm just going to link to the files instead of attaching.  I made simple
tests for `array_fill_keys()`, but I couldn't add a new file to CVS, so it's a
separate file.  I don't have diffs online yet for PHP_5_2 -- wanted to get
these looked at first. :-)

http://realplain.com/php/array_fill_keys.diff
http://realplain.com/php/array_fill_keys.phpt

Thanks if you give this attention,
Matt
