increment $VERSION after 1.003029 release
[p5sagit/Devel-REPL.git] / lib / Devel / REPL / Plugin / Refresh.pm
CommitLineData
1716b200 1use strict;
2use warnings;
13e18b1b 3package Devel::REPL::Plugin::Refresh;
9d2a4940 4# ABSTRACT: Reload libraries with Module::Refresh
13e18b1b 5
77327851 6our $VERSION = '1.003030';
54beb05d 7
6a5409bc 8use Devel::REPL::Plugin;
aa8b7647 9use namespace::autoclean;
13e18b1b 10use Module::Refresh;
11
12# before evaluating the code, ask Module::Refresh to refresh
13# the modules that have changed
14around 'eval' => sub {
15 my $orig = shift;
16 my ($self, $line) = @_;
17
18 # first refresh the changed modules
19 Module::Refresh->refresh;
20
21 # the eval the code
22 return $self->$orig($line);
23};
24
251;