use Scalar::Util qw(weaken);
use base qw(Exporter);
-our $VERSION = '1.003000';
+our $VERSION = '1.003001';
$VERSION = eval $VERSION;
our @EXPORT = qw(quote_sub unquote_sub quoted_from_sub);
(ref($_[-1]) eq 'HASH' and ref($_[-2]) eq 'HASH')
? pop
: {};
- my $captures = pop if ref($_[-1]) eq 'HASH';
+ my $captures = ref($_[-1]) eq 'HASH' ? pop : undef;
undef($captures) if $captures && !keys %$captures;
my $code = pop;
my $name = $_[0];
}
1;
+__END__
=head1 NAME
C<$code> is a string that will be turned into code.
C<\%captures> is a hashref of variables that will be made available to the
-code. See the L</SYNOPSIS>'s C<Silly::dagron> for an example using captures.
+code. The keys should be the full name of the variable to be made available,
+including the sigil. The values should be references to the values. The
+variables will contain copies of the values. See the L</SYNOPSIS>'s
+C<Silly::dagron> for an example using captures.
=head3 options
=head1 COPYRIGHT AND LICENSE
See L<Moo> for the copyright and license.
+
+=cut