svn: /phpdoc/en/trunk/reference/bc/functions/ bcpow.xml
| From: | Adam Harvey | Date: | Thu, 09 Sep 2010 05:45:41 +0000 |
| Subject: | svn: /phpdoc/en/trunk/reference/bc/functions/ bcpow.xml | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-7087@lists.php.net to get a copy of this message | ||
aharvey Thu, 09 Sep 2010 05:45:41 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=303202
Log:
Fix (doc) bug #52748 (bcpow() - scale parameter doesn't influensce the result
string) by adding a clarifying note about bcpow's exact behaviour when dealing
with scale.
Bug: http://bugs.php.net/52748 (Assigned) bcpow() - scale
parameter doesn't influensce the result string
Changed paths:
U phpdoc/en/trunk/reference/bc/functions/bcpow.xml
Modified: phpdoc/en/trunk/reference/bc/functions/bcpow.xml
===================================================================
--- phpdoc/en/trunk/reference/bc/functions/bcpow.xml 2010-09-09 05:24:51 UTC (rev 303201)
+++ phpdoc/en/trunk/reference/bc/functions/bcpow.xml 2010-09-09 05:45:41 UTC (rev 303202)
@@ -67,6 +67,28 @@
</programlisting>
</example>
</refsect1>
+
+ <refsect1 role="notes">
+ &reftitle.notes;
+ <note>
+ <para>
+ <function>bcpow</function> may return a result with fewer digits after the
+ decimal point than the <parameter>scale</parameter> parameter would
+ indicate. This only occurs when the result doesn't require all of the
+ precision allowed by the <parameter>scale</parameter>. For example:
+ <example>
+ <title><function>bcpow</function> scale example</title>
+ <programlisting role="php">
+<![CDATA[
+<?php
+echo bcpow('5', '2', 2); // prints "25", not "25.00"
+?>
+]]>
+ </programlisting>
+ </example>
+ </para>
+ </note>
+ </refsect1>
<refsect1 role="seealso">
&reftitle.seealso;