Example #1
0
 function recipientOfBenchDurationForCallableIs(callable $callable, bench\duration\recipient $recipient)
 {
     $start = microtime(true);
     $callable();
     $recipient->benchDurationIs(new time\duration\second\micro(new risingsun\ofloat(microtime(true) - $start)));
     return $this;
 }
Example #2
0
 function recipientOfBenchDurationForCallableIs(callable $callable, risingsun\bench\duration\recipient $recipient)
 {
     $bench = clone $this;
     $bench = self::durationIsBlackholeForBench($bench);
     $bench->bench->recipientOfBenchDurationForCallableIs($callable, $bench);
     $bench->bench->recipientOfLoopNumberIs($bench);
     $recipient->benchDurationIs($bench->duration);
     return $this;
 }