| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This was originally reported againt 5.36.0 where ^D would act
more like 'n' than 'q':
$ ~/perl/v5.36.0-clang14/bin/perl -lde 'print 1; print 2; print 3;'
Loading DB routines from perl5db.pl version 1.73
Editor support available.
Enter h or 'h h' for help, or 'man perldebug' for more help.
main::(-e:1): print 1; print 2; print 3;
DB<1> 1
main::(-e:1): print 1; print 2; print 3;
DB<1> 2
main::(-e:1): print 1; print 2; print 3;
DB<1> 3
(^D at each prompt)
Post 80c1f1e4 this behaved a little differently, since reading ^D
from the stream now sets the eof() flag readline() would return
immediately after each attempt, instead of reading a command.
This produced the same output as above, but only required a single ^D.
But neither of these is correct, both 'q' and ^D are documented to
exit the debugger, and 'q' does that, this changes eof to also
exit the debugger.
Unfortunately the perl5db test infrastructure doesn't support
testing this, and due to the way the debugger interacts with the
terminal, I don't think this is easily tested in core. I think
a module like Expect or IPC::Run that can interact with a terminal
would be needed.
|
|
|
|
|
|
| |
`R` command: pure man -> poor man
Probably meant that:
https://en.wiktionary.org/wiki/poor_man%27s#English
|
|
|
|
|
|
|
|
| |
Fix: then -> them
Also corrected "dumpvar.pl" to be rendered as a file name in POD rather than code/command.
https://perldoc.perl.org/perlpod#F-used-for-filenames
Bumped Perl Debugger version to pass t/porting/cmp-version.t test
|
| |
|
| |
|
|
|
|
| |
These internal references are linkable
|
|
|
|
|
|
|
|
| |
I added these to surround some C<...> that have spaces so that the
output construct is guaranteed to be on a single line. These are mostly
commands to type, and it is clearer to the reader if they kept together.
I didn't bother with things that were guaranteed to be at the beginning
of a line, as they won't wrap anyway.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
These warnings are no longer generated; so simplify the core by not
trying to turn them off.
The warning is preserved so that other code need not change, but this
commit also turns the default generation of it off.
|
| |
|
|
|
|
|
|
|
|
| |
The condition has existed since eternity but it never made sense.
Only use "con" if $^O eq 'MSWin32'.
Also, remove MSDOS from the comment: it's the last forgotten mention
of the OS in the whole file.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit moves us a step forward on eliminating 'master/slave' terminology.
Its scope is limited to those files within the Perl 5 core distribution which
are not CPAN-upstream. Within that scope, we leave untouched the use of the
term 'slave' in epigraphs and other literary quotations and its use in data
coming from outside sources (e.g., Unicode code points).
Increment $VERSION in lib/perl5db.pl. Revisions per rjbs feedback.
For: https://github.com/Perl/perl5/pull/19227
|
|
|
|
|
|
| |
DJGPP is a port of the GNU toolchain to 32-bit x86 systems running DOS.
The last known attempt to build Perl on it was on 5.20, which only got
as far as building miniperl.
|
|
|
|
| |
The build has been broken since 2009.
|
|
|
|
| |
cmd_l was still mentioned in the documentation and comments.
|
| |
|
| |
|
|
|
|
|
| |
Subroutine cmd_l() no longer exists.
Now we should call cmd_l_main().
|
| |
|
|
|
|
|
| |
Since the '.' and '-' commands don't take any arguments and don't run if any are provided, don't treat commands starting with these characters as the single commands '.' and '-'. Restores behavior that existed prior to https://github.com/Perl/perl5/commit/7fdd4f080863703d44282c6988834455d129040 (v5.27) at least back to v5.8.8
https://github.com/Perl/perl5/commit/7fdd4f080863703d44282c6988834455d129040
|
| |
|
| |
|
|
|
|
|
| |
As with `i $obj` the DB::Obj in the call stack prevented DB::eval
from compiling/executing in the context of the debugged code.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
the DB::eval function depends on the special behaviour of eval ""
within the DB package, which evaluates the string within the context
of the first non-DB sub or eval scope, working up the call stack.
The debugger refactor moved handling for the 'i' command from the
DB package to the DB::Obj package, so the eval in DB::eval was
working in the context of the DB::Obj::cmd_i function, not in the
calling scope.
Fixed by moving the handling for the i command back to DB.
Fixes #17661.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This requires a few small changes.
1. add a new option, which I stored in what looked like one of the
standard ways
2. only store the item in terminal history if >= this length
3. only add to @hist if >= this length
4. only display hist item if >= this length
I believe #4 is redundant and should be removed, but the code was
already effectively there.
|
|
|
|
| |
as it's cleared right after it's been run.
|
|
|
|
|
|
|
| |
When running with "c", there was no problem, but when running with "n"
or "s", once the action was executed, it kept executing on the
following lines, which wasn't expected. Clearing $action here prevents
this unwanted behaviour.
|
|
|
|
|
| |
Mostly in comments and docs, but some in diagnostic messages and one
case of 'or die die'.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I don't know how this ever worked.
Previously, DB::sub() would hold a lock on $DB::DBGR for it's entire
body, including the call to the subroutine being called.
This could cause problems in two cases:
a) on creation of a new thread, CLONE() is called in the context of
the new interpreter before the new thread is created. So you'd have a
sequence like:
threads->new
DB::sub for threads::new (lock $DBGR)
call into threads::new which creates a new interpreter
Cwd::CLONE() (in the new interpreter)
DB::sub for Cwd::CLONE (in the new interpreter) (deadlock trying to lock $DBGR)
One workaround I tried for this was to prevent pp_entersub calling
DB::sub if we were cloning (by checking PL_ptr_table). This did
improve matters, but wasn't needed in the final patch.
Note that the recursive lock on $DBGR would have been fine if the new
code was executing in the same interpreter, since the locking code
simply bumps a reference count if the current interpreter already
holds the lock.
b) when the called subroutine blocks. For the test case this could
happen with the call to $thr->join. There would be a sequence like:
(parent) $thr->join
(parent) DB::sub for threads::join (lock $DBGR)
(parent) call threads::join and block
(child) try to call main::sub1
(child) DB::sub for main::sub1 (deadlock trying to lock $DBGR)
This isn't limited to threads::join obviously, one thread could be
waiting for input, sleeping, or performing a complex calculation.
The solution I chose here was the obvious one - don't hold the lock
for the actual call.
This required some rearrangement of the code and removed some
duplication too.
|
|
|
|
|
|
|
|
| |
Committer: For porting tests: Update $VERSION in 4 files.
Run:
./perl -Ilib regen/mk_invlists.pl
./perl -Ilib regen/regcharclass.pl
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
dump_trace() prints a stack backtrace - including caller args - by using
caller() and @DB::args.
However, if a sub is called using the '&foo;' argless mechanism, caller()
doesn't populate @DB::args, so it continues to hold whatever it was set
to previously. This might include SVs which have since been freed or
re-allocated.
So only display args for a particular caller depth if that sub was called
with args.
This was causing smoke failures in lib/perl5db.t when TERM was unset.
It only started failing recently, due I guess to subtle changes in what
SVs were left hanging about in @DB::args from a previous use of caller().
See http://nntp.perl.org/group/perl.perl5.porters/247032
Subject: Smoke FAIL's for lib/perl5db.t
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Make debugger commands like these work again, not requiring a space
between a single-letter command and a following argument which starts with
punctuation:
p$^V
x@ARGV
x\@ARGV
x\%INC
Regressions were in d478d7a0 and 8f144dfc.
|
|
|
|
|
|
|
|
|
| |
If a Win32 system happens to have a \dev\tty file at the root of the current
drive, we were incorrectly treating that as an indicator that the system is
in fact Unix-like.
Fix this by looking at the filesystem for that file only after considering
all the OS platforms that we know aren't Unix-like in that way.
|
|
|
|
|
|
|
|
|
|
| |
Switch from two-argument form. Filehandle cloning is still done with the two
argument form for backward compatibility.
Committer: Get all porting tests to pass. Increment some $VERSIONs.
Run: ./perl -Ilib regen/mk_invlists.pl; ./perl -Ilib regen/regcharclass.pl
For: RT #130122
|
|
|
|
|
|
| |
Add a note about version numbering, since if we use X.XX_XX versions
in blead it's harder to find an unused version number if the module
is modified in maint.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Patch submitted by Shlomi Fish.
For: RT #126735
|
|
|
|
|
| |
Credits to Heiko Eissfeldt for the reported bug, the test program and a
proposed fix.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
cde405a6b9b86bd8110f63531b42d89590a4c56e removed the lock prototype
"because it's already a do-nothing weak keyword without threads".
However, that causes "perl -d threaded-script.pl" to complain
lock can only be used on shared values at /usr/share/perl/5.20/perl5db.pl line 4101.
BEGIN failed--compilation aborted at threaded-script.pl line 2.
lock can only be used on shared values at /usr/share/perl/5.20/perl5db.pl line 2514.
END failed--call queue aborted at threaded-script.pl line 2.
Unbalanced scopes: 3 more ENTERs than LEAVEs
because threaded-script.pl's importing of threads::shared enable's
lock()'s non-noop behavior. Restoring the lock() prototype fixes the
inconsistency between lock() and share() usage.
Signed-off-by: James McCoy <vega.james@gmail.com>
|
| |
|
| |
|