jeroen Wed May 16 08:27:52 2001 EDT
Modified files:
/phpdoc/en/functions gmp.xml
Log:
Added warning to gmp_init
Index: phpdoc/en/functions/gmp.xml
diff -u phpdoc/en/functions/gmp.xml:1.7 phpdoc/en/functions/gmp.xml:1.8
--- phpdoc/en/functions/gmp.xml:1.7 Thu Mar 8 02:47:17 2001
+++ phpdoc/en/functions/gmp.xml Wed May 16 08:27:52 2001
@@ -86,6 +86,25 @@
</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