in reply to Re: Fun with Prototypes
in thread Fun with Prototypes

an example avoiding a sub-call, unfortunately the division in void context is not optimized away.

and the warning will create runtime overhead, too :/

update
But I think a little overhead is acceptable when debugging.

another edge case are empty arrays causing a division by zero...

update:

fixed minor bug

Cheers Rolf
(addicted to the Perl Programming Language and ☆☆☆☆ :)
Je suis Charlie!