Added warning to gmp_init

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@47587 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Jeroen van Wolffelaar 2001-05-16 15:27:52 +00:00
parent 739c68b9a4
commit 6ea02e0092

View file

@ -86,6 +86,25 @@ print gmp_strval (fact (1000)) . "\n";
</programlisting>
</example>
</para>
<warning>
<para>
If you want to explicitely specify an integer, do not use
<literal>gmp_init(12378473895798475827348979342)</literal>,
since first the integer-literal will be interpreted,
resulting in an
<link linkend="language.types.integer.overflow">overflow</link>
and thus in zero, and then gmp_init is called with that
zero as argument.
<!-- TODO: wrong, it will be converted to float (type-jug), which
will lead to loss of precision. -->
</para>
<simpara>
Instead, use
<literal>gmp_init('12378473895798475827348979342')</literal>
</simpara>
</warning>
<note>
<para>
It is not necessary to call this function if you want to use