-
Notifications
You must be signed in to change notification settings - Fork 534
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PATCH] Fix a tab-completion bug in perl -d with Term::ReadLine::Gnu #13482
Comments
From @shlomifHi all, I noticed that when I type "$F" and then tab complete inside perl -d with <<<< Loading DB routines from perl5db.pl version 1.39_10 Enter h or 'h h' for help, or 'man perldebug' for more help. main::(euler-160.pl:8): my $N = abs(int($ENV{N} || 1_000_000_000_000)); The attached patch fixes it by adding "do { no strict 'refs'; ...}". I didn't Regards, Shlomi Fish -- Shlomi Fish http://www.shlomifish.org/ Judaism: God knows you will do shit, does nothing to prevent it, but makes you Please reply to list if it's a mailing list post - http://shlom.in/reply . |
From @shlomif0001-Crash-in-tab-completion-with-Term-ReadLine-Gnu.patchFrom 825f77698d75d6801c86cef0c1dc253ed7690043 Mon Sep 17 00:00:00 2001
From: Shlomi Fish <shlomif@shlomifish.org>
Date: Thu, 19 Dec 2013 13:06:42 +0200
Subject: [PATCH] Crash in tab completion with Term::ReadLine::Gnu.
Perhaps it also affects Term::ReadLine::Perl / Term::ReadLine::Perl5 .
I still need to test with PadWalker installed. No tests were added, but
it passes all existing tests.
---
lib/perl5db.pl | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/perl5db.pl b/lib/perl5db.pl
index ab82616..c1d6752 100644
--- a/lib/perl5db.pl
+++ b/lib/perl5db.pl
@@ -523,7 +523,7 @@ BEGIN {
# Debugger for Perl 5.00x; perl5db.pl patch level:
use vars qw($VERSION $header);
-$VERSION = '1.42';
+$VERSION = '1.43';
$header = "perl5db.pl version $VERSION";
@@ -9385,7 +9385,7 @@ If the package is C<::> (C<main>), create an empty list; if it's something else,
=cut
push @out, map "$prefix$_", grep /^\Q$text/,
- ( grep /^_?[a-zA-Z]/, keys %$pack ),
+ ( grep /^_?[a-zA-Z]/, do { no strict 'refs'; keys %$pack } ),
( $pack eq '::' ? () : ( grep /::$/, keys %:: ) );
=item *
--
1.8.4.5
|
From @tonycozOn Thu Dec 19 03:30:53 2013, shlomif@shlomifish.org wrote:
Thanks, applied to blead as c3970b8. I looked at writing a test for this, but encountered a different crash I think Tony |
|
The RT System itself - Status changed from 'new' to 'open' |
From @shlomifHi, On Sun, 5 Jan 2014 16:27:36 -0800
Thanks, Tony! Regards, Shlomi Fish -- Shlomi Fish http://www.shlomifish.org/ Chuck Norris taught God how to create the universe. Please reply to list if it's a mailing list post - http://shlom.in/reply . |
From @shlomifOn Sun Jan 05 16:27:35 2014, tonyc wrote:
This patch also needs to be tested and applied at the maintperl-5.18.x branch for perl-5.18.3. Regards, -- Shlomi Fish |
From @shlomifHi, On Mon Jan 06 22:53:45 2014, shlomif wrote:
the patch after the "git cherry-pick" is attached to this message. It can also be found here: https://github.com/shlomif/perl/tree/maint-5.18 Regards, -- Shlomi Fish |
From @shlomif0001-Crash-in-tab-completion-with-Term-ReadLine-Gnu.patchFrom b6bdb6054730aa2245b95fbcb5ce71ea76641805 Mon Sep 17 00:00:00 2001
From: Shlomi Fish <shlomif@shlomifish.org>
Date: Thu, 19 Dec 2013 13:06:42 +0200
Subject: [PATCH] Crash in tab completion with Term::ReadLine::Gnu.
Perhaps it also affects Term::ReadLine::Perl / Term::ReadLine::Perl5 .
I still need to test with PadWalker installed. No tests were added, but
it passes all existing tests.
Conflicts:
lib/perl5db.pl
---
lib/perl5db.pl | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/perl5db.pl b/lib/perl5db.pl
index bcb4dd5..da532fb 100644
--- a/lib/perl5db.pl
+++ b/lib/perl5db.pl
@@ -523,7 +523,7 @@ BEGIN {
# Debugger for Perl 5.00x; perl5db.pl patch level:
use vars qw($VERSION $header);
-$VERSION = '1.39_10';
+$VERSION = '1.39_11';
$header = "perl5db.pl version $VERSION";
@@ -9511,7 +9511,7 @@ If the package is C<::> (C<main>), create an empty list; if it's something else,
=cut
push @out, map "$prefix$_", grep /^\Q$text/,
- ( grep /^_?[a-zA-Z]/, keys %$pack ),
+ ( grep /^_?[a-zA-Z]/, do { no strict 'refs'; keys %$pack } ),
( $pack eq '::' ? () : ( grep /::$/, keys %:: ) );
=item *
--
1.8.4.5
|
From @tonycozOn Mon Jan 06 23:40:10 2014, shlomif wrote:
I believe this should be backported to maint-5.18, since it's a regression. Looking for two more votes. Tony |
From perl5-porters@perl.orgTony Cook wrote:
It gets mine. |
From @rjbs* Tony Cook via RT <perlbug-followup@perl.org> [2014-01-08T19:24:49]
+1 -- |
From @shlomifOn Wed Jan 08 16:24:49 2014, tonyc wrote:
There were two votes - one from Father C, and one from RJBS. Can this patch be applied now to maint-5.18.x? Regards, -- Shlomi Fish |
|
@tonycoz - Status changed from 'open' to 'resolved' |
From @shlomifOn Sun, 12 Jan 2014 19:59:11 -0800
Thanks! -- Shlomi Fish
-- Shlomi Fish http://www.shlomifish.org/ Chuck Norris won the Nobel Peace Prize. For making millions of people rest Please reply to list if it's a mailing list post - http://shlom.in/reply . |
Migrated from rt.perl.org#120827 (status was 'resolved')
Searchable as RT120827$
The text was updated successfully, but these errors were encountered: