use Test::More tests => 9; BEGIN { use_ok('arguments') }; do { my $f; $f = sub { ok($f eq arguments::callee); }; }->(); sub { my $c = shift; ok($c); arguments::callee->($c) if (--$c); }->(3); my $n = sub { my $x = shift; return 1 if ($x <= 1); return $x * (arguments::callee->($x - 1)); }->(5); ok($n == 120); sub func { ok(arguments->callee eq \&func); ok(arguments->length == 3); my @a = arguments(); ok(scalar @a == 3); } func(1,2,3);