note 93087 deleted from language.oop5 by danbrown
| From: | danbrown@php.net | Date: | Sat, 22 Aug 2009 19:18:33 +0000 |
| Subject: | note 93087 deleted from language.oop5 by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-159790@lists.php.net to get a copy of this message | ||
Note Submitter: canyon at example.com
----
to redrik at gmail dot com
Thanks for this, your code force to recalculate $args in each iteration, it would be more fine to
calculate before, like this:
$args = func_get_args();
$n=count($args);
for( $i=0; $i<$n; $i++ )
$this->add($args[$i]);
instead of this one:
$args = func_get_args();
for( $i=0, $n=count($args); $i<$n; $i++ )
$this->add($args[$i]);
Cordially.