|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2011-12-29 01:16 UTC] hanskrentel at yahoo dot de
[2011-12-29 12:42 UTC] login dot naitsirch at arcor dot de
[2012-03-03 19:45 UTC] iliaa@php.net
-Status: Open
+Status: Not a bug
[2012-03-03 19:45 UTC] iliaa@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Dec 04 17:00:01 2025 UTC |
Description: ------------ Hi. I think the 'range()' function should return an array with strings, if the 'start' and 'limit' arguments are numeric strings. Otherwise it should be mentioned in the documentation. Test script: --------------- <?php var_dump(range('0', '9')); Expected result: ---------------- array(10) { [0]=> string(1) "0" [1]=> string(1) "1" [2]=> string(1) "2" [3]=> string(1) "3" [4]=> string(1) "4" [5]=> string(1) "5" [6]=> string(1) "6" [7]=> string(1) "7" [8]=> string(1) "8" [9]=> string(1) "9" } Actual result: -------------- array(10) { [0]=> int(0) [1]=> int(1) [2]=> int(2) [3]=> int(3) [4]=> int(4) [5]=> int(5) [6]=> int(6) [7]=> int(7) [8]=> int(8) [9]=> int(9) }