| Log-Dump documentation | Contained in the Log-Dump distribution. |
Log::Dump::Functions
use Log::Dump::Functions; log( debug => 'foo' );
You usually want to use this for a simple script. Usage is the same as Log::Dump, except that you don't need to write __PACKAGE__-> or $self->.
Kenichi Ishigaki, <ishigaki@cpan.org>
Copyright (C) 2009 by Kenichi Ishigaki.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
| Log-Dump documentation | Contained in the Log-Dump distribution. |
package Log::Dump::Functions; use strict; use warnings; use Log::Dump; use Sub::Install 'install_sub'; our @CARP_NOT; sub import { my $class = shift; my $caller = caller; my @methods = qw( logger log logfile logfilter logcolor ); foreach my $method (@methods) { install_sub({ as => $method, into => $caller, code => sub { $class->$method(@_) }, }); } } 1; __END__