-
-
Save anonymous/0de87d1408f5e98707a1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ perl -Mojo -E 'sub Mojolicious::Controller::bar { "works!" }; my $c = app->build_controller; n { $c->bar } 100000' | |
0.0179179 wallclock secs ( 0.02 usr + 0.00 sys = 0.02 CPU) @ 5000000.00/s (n=100000) | |
$ perl -Mojo -E 'helper bar => sub { "works!" }; my $c = app->build_controller; n { $c->bar } 100000' | |
0.866315 wallclock secs ( 0.87 usr + 0.00 sys = 0.87 CPU) @ 114942.53/s (n=100000) | |
$ perl -Mojo -E 'helper foo => sub { shift }; helper bar => sub { "works!" }; my $c = app->build_controller; n { $c->foo->bar } 100000' | |
1.6739 wallclock secs ( 1.67 usr + 0.00 sys = 1.67 CPU) @ 59880.24/s (n=100000) | |
$ perl -Mojo -E 'helper "foo.bar" => sub { "works!" }; my $c = app->build_controller; n { $c->foo->bar } 100000' | |
1.79191 wallclock secs ( 1.80 usr + 0.00 sys = 1.80 CPU) @ 55555.56/s (n=100000) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment