Data-Show
view release on metacpan or search on metacpan
lib/Data/Show.pm view on Meta::CPAN
# Skip almost everything if "no Data::Show"...
if (!$hints_ref->{'Data::Show/noshow'}) {
# Identify current lexically-scoped config (should already have been loaded by import())...
my $plugin_class = $hints_ref->{'Data::Show/with'} // $FINAL_CANDIDATE_PLUGIN;
my %style = %{ $STYLE[ $hints_ref->{'Data::Show/style'} ] };
my $termwidth = $hints_ref->{'Data::Show/termwidth'};
# Warn about side-effects of multi-arg calls to show() in scalar context...
if (defined $call_context && !$call_context && @_ > 1) {
warn "Call to show() may not be not transparent at $file line $line\n";
}
# Serialize Contextual::Return objects (can break some dumpers in the Data::Dump family)...
my @data = map { ref() =~ m{\AContextual::Return::Value}
? do {my $v = $_->Contextual::Return::DUMP(); $v =~ s[\}\n][\},\n]gxms; eval $v; }
: $_
} @_;
# Extract the originating source line(s)...
my ($pre_source, $source, $post_source, $startline)
lib/Data/Show.pm view on Meta::CPAN
=item C<< Used <FALLBACK> in place of <PLUGIN> >>
You requested a plugin that could not be loaded,
so the best available fallback was used instead.
You would have also received one or more of the three preceding
diagnostics. Consult their entries for suggestions on silencing
this warning.
=item C<< Call to show() may not be not transparent >>
The call to C<show()> has been inserted into a scalar context,
but was passed two or more arguments to dump. This can change
the behaviour of the surrounding code. For example, consider
the following statements:
my @list = (
abs $x,
exp $y,
sqrt $z,
( run in 0.498 second using v1.01-cache-2.11-cpan-0a6323c29d9 )