X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2FDevel-REPL.git;a=blobdiff_plain;f=lib%2FDevel%2FREPL%2FPlugin%2FLexEnv.pm;h=4a272d156108f6a06b1ff51ee4766f91d8333040;hp=ea6d26b3d18983645d86af6f2067572845fe5b84;hb=6d22063d380fc145987db58a1b6222a33a596c3e;hpb=310ddf9f9d5d370f7b4aa89e7bbf4fd7f6a3814f diff --git a/lib/Devel/REPL/Plugin/LexEnv.pm b/lib/Devel/REPL/Plugin/LexEnv.pm index ea6d26b..4a272d1 100644 --- a/lib/Devel/REPL/Plugin/LexEnv.pm +++ b/lib/Devel/REPL/Plugin/LexEnv.pm @@ -44,14 +44,17 @@ around 'execute' => sub { return $self->$orig($wrapped, @rest); }; -around 'find_variable' => sub { - my $orig = shift; - my ($self, $name) = @_; - - return \( $self->lexical_environment->get_context('_')->{$name} ) - if exists $self->lexical_environment->get_context('_')->{$name}; - - return $orig->(@_); -}; +# this doesn't work! yarg. we now just check $self->can('lexical_environment') +# in FindVariable + +#around 'find_variable' => sub { +# my $orig = shift; +# my ($self, $name) = @_; +# +# return \( $self->lexical_environment->get_context('_')->{$name} ) +# if exists $self->lexical_environment->get_context('_')->{$name}; +# +# return $orig->(@_); +#}; 1;