Devel-Trepan

 view release on metacpan or  search on metacpan

lib/Devel/Trepan/DB/LineCache.pm  view on Meta::CPAN

=head2 update_script_cache

B<update_script_cache($script, $opts)> => I<boolean>

Update a cache entry for an pseudo eval-string file name. If something
is wrong, return I<undef>. Return I<true> if the cache was updated and
I<false> if not.

=cut

sub update_script_cache($$)
{
    my ($script, $opts) = @_;
    return 0 unless filename_is_eval($script);
    my $string = $opts->{string};
    my $lines_href = {};
    if (defined($string)) {
        my @lines = split(/\n/, $string);
        $lines_href->{plain} = \@lines;
    } else {
        if ($script eq $DB::filename) {

 view all matches for this distribution
 view release on metacpan -  search on metacpan

( run in 0.561 second using v1.00-cache-2.02-grep-82fe00e-cpan-4673cadbf75 )