[Bast-commits] r4411 - trunk/Devel-REPL/lib/Devel/REPL/Plugin
Sartak at dev.catalyst.perl.org
Sartak at dev.catalyst.perl.org
Mon May 26 04:22:06 BST 2008
Author: Sartak
Date: 2008-05-26 04:22:06 +0100 (Mon, 26 May 2008)
New Revision: 4411
Modified:
trunk/Devel-REPL/lib/Devel/REPL/Plugin/LexEnv.pm
Log:
Return a reference to the correct lexical variable (not the copy)
Modified: trunk/Devel-REPL/lib/Devel/REPL/Plugin/LexEnv.pm
===================================================================
--- trunk/Devel-REPL/lib/Devel/REPL/Plugin/LexEnv.pm 2008-05-26 03:20:03 UTC (rev 4410)
+++ trunk/Devel-REPL/lib/Devel/REPL/Plugin/LexEnv.pm 2008-05-26 03:22:06 UTC (rev 4411)
@@ -47,8 +47,10 @@
around 'find_variable' => sub {
my $orig = shift;
my ($self, $name) = @_;
- my $variable = $self->lexical_environment->get_context('_')->{$name};
- return \$variable if $variable;
+
+ return \( $self->lexical_environment->get_context('_')->{$name} )
+ if exists $self->lexical_environment->get_context('_')->{$name};
+
return $orig->(@_);
};
More information about the Bast-commits
mailing list