note 115464 added to function.bcscale

From: Date: Mon, 28 Jul 2014 20:47:26 +0000
Subject: note 115464 added to function.bcscale
Groups: php.notes 
Request: Send a blank email to php-notes+get-200065@lists.php.net to get a copy of this message
Keep in mind that the documentation states "all subsequent calls to bc math functions" and should be handled as if changing a global PHP ini setting via ini_set. This applies to object instantiation as well and will not reset after the object is no longer in use as would normally be expected. <?php class foo { public function __construct() { \bcscale(5); new bar; } } class bar { public function __construct() { \var_dump(\bcadd('1', '2')); } } new bar; //string(1) "3" $foo = new foo; //string(7) "3.00000" unset($foo); //disposal of object new bar; //string(7) "3.00000" ?> ---- Server IP: 72.52.91.14 Probable Submitter: 50.79.80.225 ---- Manual Page -- http://php.net/manual/en/function.bcscale.php Edit -- https://master.php.net/note/edit/115464 Del: integrated -- https://master.php.net/note/delete/115464/integrated Del: useless -- https://master.php.net/note/delete/115464/useless Del: bad code -- https://master.php.net/note/delete/115464/bad+code Del: spam -- https://master.php.net/note/delete/115464/spam Del: non-english -- https://master.php.net/note/delete/115464/non-english Del: in docs -- https://master.php.net/note/delete/115464/in+docs Del: other reasons-- https://master.php.net/note/delete/115464 Reject -- https://master.php.net/note/reject/115464 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#200065) next »