in reply to Enforcing formal arguments at compile time?
That way when your code goes into prodution you can have Perl optimize away the assertions by changing the use to a nouse Carp::Assert; sub foo { is(scalar @_, 2) if DEBUG; }
I definately dislike it when code uses prototypes for doing this type of thing. The trade-offs are unacceptable.no Carp::Assert;
Yves / DeMerphq
---
Writing a good benchmark isnt as easy as it might look.
|
|---|