Skip to content

Commit bf672f5

Browse files
authored
random: clarify that getrandmax was small only before PHP 7.1 (#4664)
Since PHP 7.1 `getrandmax` is an alias of `mt_getrandmax`, which returns 2**31 - 1
1 parent c532ece commit bf672f5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

reference/random/functions/rand.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727
&caution.cryptographically-insecure;
2828
<note>
2929
<simpara>
30-
On some platforms (such as Windows), <function>getrandmax</function>
31-
is only 32767. If you require a range larger than 32767, specifying
30+
Prior to PHP 7.1.0, <function>getrandmax</function> was only 32767 on some
31+
platforms (such as Windows). If you require a range larger than 32767, specifying
3232
<parameter>min</parameter> and <parameter>max</parameter> will allow
3333
you to create a range larger than this, or consider using
3434
<function>mt_rand</function> instead.

0 commit comments

Comments
 (0)