App-ppgrep
view release on metacpan or search on metacpan
script/_ppgrep view on Meta::CPAN
# for my $phase (keys %$hooks) {
# my $hook = $hooks->{$phase};
# if (defined $args{target}) {
# add_per_target_hook(
# $args{target}, $args{target_arg}, $phase, $hook);
# } else {
# add_hook($phase, $hook);
# }
# }
#
# my $reinit = $args{reinit};
# $reinit = 1 unless defined $reinit;
# if ($reinit) {
# if (defined $args{target}) {
# reinit_target($args{target}, $args{target_arg});
# } else {
# reinit_all_targets();
# }
# }
#}
#
#1;
## ABSTRACT: Utility routines for Log::ger
#
#__END__
#
#=pod
#
#=encoding UTF-8
#
#=head1 NAME
#
#Log::ger::Util - Utility routines for Log::ger
#
#=head1 VERSION
#
#version 0.028
#
#=head1 DESCRIPTION
#
#This package is created to keep Log::ger as minimalist as possible.
#
#=for Pod::Coverage ^(.+)$
#
#=head1 AUTHOR
#
#perlancar <perlancar@cpan.org>
#
#=head1 COPYRIGHT AND LICENSE
#
#This software is copyright (c) 2019, 2018, 2017 by perlancar@cpan.org.
#
#This is free software; you can redistribute it and/or modify it under
#the same terms as the Perl 5 programming language system itself.
#
#=cut
### Mo.pm ###
#package Mo;
#$Mo::VERSION = '0.40';
#$VERSION='0.40';
#no warnings;my$M=__PACKAGE__.'::';*{$M.Object::new}=sub{my$c=shift;my$s=bless{@_},$c;my%n=%{$c.'::'.':E'};map{$s->{$_}=$n{$_}->()if!exists$s->{$_}}keys%n;$s};*{$M.import}=sub{import warnings;$^H|=1538;my($P,%e,%o)=caller.'::';shift;eval"no Mo::$_",&...
### Mo/Golf.pm ###
###
## name: Mo::Golf
## abstract: Module for Compacting Mo Modules
## author: Ingy döt Net <ingy@ingy.net>
## license: perl
## copyright: 2011
## see:
## - Mo
#
#use strict;
#use warnings;
#package Mo::Golf;
#
#our $VERSION='0.40';
#
#use PPI;
#
## This is the mapping of common names to shorter forms that still make some
## sense.
#my %short_names = (
# (
# map {($_, substr($_, 0, 1))}
# qw(
# args builder class default exports features
# generator import is_lazy method MoPKG name
# nonlazy_defaults options reftype self
# )
# ),
# build_subs => 'B',
# old_constructor => 'C',
# caller_pkg => 'P',
#);
#
#my %short_barewords = ( EAGERINIT => q{':E'}, NONLAZY => q{':N'} );
#
#my %hands_off = map {($_,1)} qw'&import *import';
#
#sub import {
# return unless @_ == 2 and $_[1] eq 'golf';
# binmode STDOUT;
# my $text = do { local $/; <> };
# print STDOUT golf( $text );
#};
#
#sub golf {
# my ( $text ) = @_;
#
# my $tree = PPI::Document->new( \$text );
#
# my %finder_subs = _finder_subs();
#
# my @order = qw( comments duplicate_whitespace whitespace trailing_whitespace );
#
# for my $name ( @order ) {
# my $elements = $tree->find( $finder_subs{$name} );
# die $@ if !defined $elements;
# $_->delete for @{ $elements || [] };
# }
#
script/_ppgrep view on Meta::CPAN
#}
#
#sub load {
# die 'load() not implemented in this class.';
#}
#
#1;
### YAML/Old/Marshall.pm ###
#use strict; use warnings;
#package YAML::Old::Marshall;
#
#use YAML::Old::Node ();
#
#sub import {
# my $class = shift;
# no strict 'refs';
# my $package = caller;
# unless (grep { $_ eq $class} @{$package . '::ISA'}) {
# push @{$package . '::ISA'}, $class;
# }
#
# my $tag = shift;
# if ( $tag ) {
# no warnings 'once';
# $YAML::TagClass->{$tag} = $package;
# ${$package . "::YamlTag"} = $tag;
# }
#}
#
#sub yaml_dump {
# my $self = shift;
# no strict 'refs';
# my $tag = ${ref($self) . "::YamlTag"} || 'perl/' . ref($self);
# $self->yaml_node($self, $tag);
#}
#
#sub yaml_load {
# my ($class, $node) = @_;
# if (my $ynode = $class->yaml_ynode($node)) {
# $node = $ynode->{NODE};
# }
# bless $node, $class;
#}
#
#sub yaml_node {
# shift;
# YAML::Old::Node->new(@_);
#}
#
#sub yaml_ynode {
# shift;
# YAML::Old::Node::ynode(@_);
#}
#
#1;
### YAML/Old/Mo.pm ###
#package YAML::Old::Mo;
## use Mo qw[builder default import];
## The following line of code was produced from the previous line by
## Mo::Inline version 0.40
#no warnings;my$M=__PACKAGE__.'::';*{$M.Object::new}=sub{my$c=shift;my$s=bless{@_},$c;my%n=%{$c.'::'.':E'};map{$s->{$_}=$n{$_}->()if!exists$s->{$_}}keys%n;$s};*{$M.import}=sub{import warnings;$^H|=1538;my($P,%e,%o)=caller.'::';shift;eval"no Mo::$_",&...
#
#our $DumperModule = 'Data::Dumper';
#
#my ($_new_error, $_info, $_scalar_info);
#
#no strict 'refs';
#*{$M.'Object::die'} = sub {
# my $self = shift;
# my $error = $self->$_new_error(@_);
# $error->type('Error');
# Carp::croak($error->format_message);
#};
#
#*{$M.'Object::warn'} = sub {
# my $self = shift;
# return unless $^W;
# my $error = $self->$_new_error(@_);
# $error->type('Warning');
# Carp::cluck($error->format_message);
#};
#
## This code needs to be refactored to be simpler and more precise, and no,
## Scalar::Util doesn't DWIM.
##
## Can't handle:
## * blessed regexp
#*{$M.'Object::node_info'} = sub {
# my $self = shift;
# my $stringify = $_[1] || 0;
# my ($class, $type, $id) =
# ref($_[0])
# ? $stringify
# ? &$_info("$_[0]")
# : do {
# require overload;
# my @info = &$_info(overload::StrVal($_[0]));
# if (ref($_[0]) eq 'Regexp') {
# @info[0, 1] = (undef, 'REGEXP');
# }
# @info;
# }
# : &$_scalar_info($_[0]);
# ($class, $type, $id) = &$_scalar_info("$_[0]")
# unless $id;
# return wantarray ? ($class, $type, $id) : $id;
#};
#
##-------------------------------------------------------------------------------
#$_info = sub {
# return (($_[0]) =~ qr{^(?:(.*)\=)?([^=]*)\(([^\(]*)\)$}o);
#};
#
#$_scalar_info = sub {
# my $id = 'undef';
# if (defined $_[0]) {
# \$_[0] =~ /\((\w+)\)$/o or CORE::die();
# $id = "$1-S";
# }
# return (undef, undef, $id);
#};
( run in 1.839 second using v1.01-cache-2.11-cpan-8f98c5d2c55 )