Christoph Michael Becker
930f983b23
Fix example wrt. recent PHP versions
...
As of PHP 7.3.0, the usage of undefined variables with compact() trigger
a notice, and as their support should be considered legacy behavior.
Therefore we remove the variable from the example.
Patch provided by anonymous user.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347684 c90b9560-bf6c-de11-be94-00142212c4b1
2019-06-30 09:39:45 +00:00
George Peter Banyard
787e0e625e
Change signature to respect new PHP 7.4 changelog. Added that these functions return an empty array if called without any arguments.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347508 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-29 11:45:11 +00:00
George Peter Banyard
1415a3b592
Forgot to change parameter numbers during copy/paste.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347501 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-28 13:11:17 +00:00
George Peter Banyard
a26b14769f
Added changelog for PHP 7.4
...
c.f. 77cf3d7b11
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347500 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-28 13:07:19 +00:00
George Peter Banyard
108ea73be5
Adapted documentation of NULL callback per PHPDoc Editor request.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347465 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-21 19:56:39 +00:00
George Peter Banyard
13d24878bd
Add a note that NULL can be used as a callback and an additional example showing that array-map returns the original array if only one array is provided with a NULL callback.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347462 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-21 16:15:12 +00:00
George Peter Banyard
821b199e5c
Replace type element by corresponding entity.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347430 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-16 21:16:35 +00:00
Joe Watkins
7f5c1d1573
Added some &true; entities, unified examples in array_filter so all match the same style guide.
...
--
Provided by anonymous 75058 (michal.brzuchalski@gmail.com )
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347421 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-15 11:39:08 +00:00
Nikita Popov
b86df9aea4
Remove warning about undefined list() behavior. At least since PHP 7 this is well-defined.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347399 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-09 10:45:19 +00:00
Christoph Michael Becker
8272e36f6a
End the notes war
...
Actual polyfill has been provided by divinity76. Thanks!
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347396 c90b9560-bf6c-de11-be94-00142212c4b1
2019-05-08 10:07:23 +00:00
Pieter Hordijk
c9c8222d0e
Adds examples of array_filter behavior with 0 string and integer. Closes #77878
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347206 c90b9560-bf6c-de11-be94-00142212c4b1
2019-04-12 09:14:23 +00:00
George Peter Banyard
9059e4a572
Improve array_slice and array_splice documentation pages.
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347119 c90b9560-bf6c-de11-be94-00142212c4b1
2019-04-01 20:22:42 +00:00
George Peter Banyard
68a9c82e06
Fix Doc Bug #66546
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347118 c90b9560-bf6c-de11-be94-00142212c4b1
2019-04-01 19:16:35 +00:00
George Peter Banyard
6d3254ed43
Fix Doc Bug #70655
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@347117 c90b9560-bf6c-de11-be94-00142212c4b1
2019-04-01 19:15:50 +00:00
Christoph Michael Becker
e1dfc3586d
Add a link to is_countable function in "see also" list of count function
...
--
Provided by anonymous 95413 (vincent.dechenaux+docphp@gmail.com )
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346403 c90b9560-bf6c-de11-be94-00142212c4b1
2018-12-20 17:48:39 +00:00
Christoph Michael Becker
05e4c11653
Clarify function signature
...
Only adding a comment to the sources isn't actually useful for readers
of the manual. Instead we split the function signature.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346086 c90b9560-bf6c-de11-be94-00142212c4b1
2018-11-27 11:38:18 +00:00
Christoph Michael Becker
9eea2fa6a6
Clarify array_column()'s $index_key casting behaviour
...
Cf. <https://bugs.php.net/bug.php?id=68553 >.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@346011 c90b9560-bf6c-de11-be94-00142212c4b1
2018-11-18 00:46:41 +00:00
Christoph Michael Becker
f354c9be97
Fix #77164 : Array function document error:array_key_first
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345985 c90b9560-bf6c-de11-be94-00142212c4b1
2018-11-15 16:47:19 +00:00
Christoph Michael Becker
d71b60f004
Fix typo
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345965 c90b9560-bf6c-de11-be94-00142212c4b1
2018-11-07 14:17:23 +00:00
Christoph Michael Becker
d8d97da74f
Fix #76971 : Changed array append behaviour of array_unique
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345783 c90b9560-bf6c-de11-be94-00142212c4b1
2018-10-06 11:43:28 +00:00
Christoph Michael Becker
f663fff2d5
Add basic array_key_first() example
...
Based on a patch provided by Nicolas Lefevre.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345623 c90b9560-bf6c-de11-be94-00142212c4b1
2018-09-11 15:58:58 +00:00
Christoph Michael Becker
3372f616cb
Be more precise
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345420 c90b9560-bf6c-de11-be94-00142212c4b1
2018-08-02 22:15:32 +00:00
Christoph Michael Becker
d3ab3ae75d
Fix #76668 : array_walk() never returns FALSE
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345396 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-26 14:38:26 +00:00
Christoph Michael Becker
b7a1a91f89
array_replace[_recursive] only requires one argument, like array_merge[_recursive]. See https://github.com/php/php-src/pull/3194
...
PS: maybe further tweak the wording...
--
Provided by anonymous 92566 ()
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345370 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-21 11:52:11 +00:00
Christoph Michael Becker
ce45d942db
$search_value of array_keys() has no default value
...
See <https://bugs.php.net/65904 >.
Based on a patch provided by an anonymous user.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345357 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-19 12:25:55 +00:00
Christoph Michael Becker
9a147ed11d
Document array_key_first() and array_key_last()
...
Cf. <https://wiki.php.net/rfc/array_key_first_last >.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345342 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-17 11:41:17 +00:00
Christoph Michael Becker
192eda7b75
Show alternative usage of array_column() in example
...
Based on a patch provided by Stefan Topfstedt.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345315 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-14 12:22:09 +00:00
Christoph Michael Becker
4fff12b319
Integrate user note 26786
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345313 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-14 11:43:33 +00:00
Christoph Michael Becker
3e4dcbc1d3
Clarify meaning of $offset parameter
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345312 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-14 11:28:25 +00:00
Christoph Michael Becker
c9558408f7
String keys are always preserved
...
Integrates user note 115717.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345311 c90b9560-bf6c-de11-be94-00142212c4b1
2018-07-14 11:05:29 +00:00
Christoph Michael Becker
fab67f0be1
Document “Allow specifying keys in list()” RFC changes
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345209 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-25 14:30:56 +00:00
Christoph Michael Becker
802fb7ce9f
Fix #76516 : shuffle() has a note about undefined sorted order
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345180 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-22 10:18:33 +00:00
Christoph Michael Becker
0ea2fa3e03
Document compact() change for 7.3
...
Based on a patch provided by Gabriel Caruso.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345170 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-19 14:55:51 +00:00
Nikita Popov
cccd50e8ed
Remove redundant note in count() docs
...
Follows from general PHP behavior (undefined variable reads as NULL) and discusses something nobody should be doing in the first place. This was probably more relevant ten years ago than it is now.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345126 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-13 14:15:05 +00:00
Christoph Michael Becker
7923a7bbfb
Add markup
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345095 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-04 11:32:38 +00:00
Christoph Michael Becker
2985b542a0
Now it is not clear what the default value for parameter flag does.
...
This patch explains it
--
Provided by anonymous 91702 (mailofjordi@gmail.com )
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345094 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-04 11:27:31 +00:00
Christoph Michael Becker
e9be040e16
Integrate user note 101775
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345049 c90b9560-bf6c-de11-be94-00142212c4b1
2018-05-25 14:09:07 +00:00
Christoph Michael Becker
126eefa0db
Clarify refpurpose
...
As suggested by a patch provided by an anonymous user.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344984 c90b9560-bf6c-de11-be94-00142212c4b1
2018-05-08 12:29:26 +00:00
Christoph Michael Becker
c35452fd96
Insert comma for clarity
...
As suggested by a patch provided by an anonymous user.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344980 c90b9560-bf6c-de11-be94-00142212c4b1
2018-05-08 12:05:17 +00:00
Christoph Michael Becker
b45d8c1772
Nested <link>s can't work
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344693 c90b9560-bf6c-de11-be94-00142212c4b1
2018-04-17 16:10:01 +00:00
Christoph Michael Becker
37949e1431
Document PR 3011
...
Cf. <https://github.com/php/php-src/pull/3011 >
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344569 c90b9560-bf6c-de11-be94-00142212c4b1
2018-03-25 21:38:29 +00:00
Christoph Michael Becker
0fe00e3574
Minor doc improvements
...
Patches provided by anonymous users.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344469 c90b9560-bf6c-de11-be94-00142212c4b1
2018-03-09 12:44:59 +00:00
Christoph Michael Becker
8b3858be3e
Fix/improve wording
...
To detect whether the array pointer points beyond the end,
we have to check whether key() returns NULL (not the opposite).
We also reword to match reset() (r343965).
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344002 c90b9560-bf6c-de11-be94-00142212c4b1
2018-01-28 12:31:16 +00:00
Christoph Michael Becker
eccca2de38
Improve wording
...
"strictly different from <type>null</type>" implies a type check,
what is not necessarily appropriate here.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343965 c90b9560-bf6c-de11-be94-00142212c4b1
2018-01-26 23:25:10 +00:00
Jakub Vrana
b8758b0605
Use entities in initializer
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343899 c90b9560-bf6c-de11-be94-00142212c4b1
2018-01-25 19:11:34 +00:00
Christoph Michael Becker
9a7ca7526c
Move essential point of the warning in the notes section up
...
Cf. <https://externals.io/message/100637 >.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343853 c90b9560-bf6c-de11-be94-00142212c4b1
2018-01-22 14:31:39 +00:00
Christoph Michael Becker
3fcc64d116
Fix #75733 : count(null) and count(empty-string) raises a warning
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343711 c90b9560-bf6c-de11-be94-00142212c4b1
2017-12-26 10:45:33 +00:00
Kalle Sommer Nielsen
27b6cff4d5
Documented that count() may yield a warning on invalid types passed to it as of 7.2.0
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343513 c90b9560-bf6c-de11-be94-00142212c4b1
2017-11-29 19:50:44 +00:00
Christoph Michael Becker
bebf0a236a
Properly refer to the value, not the type
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343124 c90b9560-bf6c-de11-be94-00142212c4b1
2017-09-21 10:53:19 +00:00
Christoph Michael Becker
fe00568fc5
Properly refer to the value, not the type
...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@343122 c90b9560-bf6c-de11-be94-00142212c4b1
2017-09-21 10:47:02 +00:00