Re: Can I not use the -E switch in the perl debugger/interpreter?



On Thu, 30 Jul 2009 08:29:02 -0700, jl_post@xxxxxxxxxxx wrote:
So my question is: Is it possible for me to use the "-E" switch in
the perl debugger/interpreter to automatically invoke the "say" feature,
or can that only be used with perl one-liners (that is, scripts written
entirely at the command line)?

The reason lies in toke.c: the debugger is loaded before -E is processed:

if (PL_perldb) {
/* Generate a string of Perl code to load the debugger.
[...]
if (PL_minus_E)
sv_catpvs(PL_linestr,
"use feature ':5." STRINGIFY(PERL_VERSION) "';");

So at the moment, the answer is no. I'll ask P5P whether it has to stay
this way.

--
Peter Scott
http://www.perlmedic.com/
http://www.perldebugged.com/
http://www.informit.com/store/product.aspx?isbn=0137001274
.



Relevant Pages

  • Major bug in Perl 5.8.2 debugger? Pager hangs
    ... that comes with Debian's Perl 5.8.2 distribution. ... command like the following while in the Perl debugger: ... printout of $some_variable) through a pager. ... one tries a debugger command like the one above, ...
    (Debian-User)
  • debugger Restart and open database connections
    ... I often use the 'R' command of the perl debugger in order to restart my ... This works by re-exec-ing the debugger. ... - Have the database drivers set the close-on-exec flag of the fd used to ...
    (perl.dbi.users)
  • Re: Bug in debugger (or my code): Bizarre copy of ARRAY...
    ... Your code looks very much like Perl 4. ... > After switching the debugger on: ... I have no idea why they syntax you used doesn't report an error or ... > Do I still have a bug in my code though it works and I do not see where it ...
    (comp.lang.perl.misc)
  • Re: dynamic scoped variables in the debugger
    ... I'm running Perl v5.8.8 compiled for linux. ... of $& in the debugger it does show "foo". ... When the program is compiled, if the compiler sees $& being used, ... It is the implementation details of this specialness that is ...
    (comp.lang.perl.misc)
  • Re: Is there any IDE for perl?
    ... There's komodo from the activestate people. ... Activestate also has a free perl install for windows that has the ... it's a visual debugger like I had back when I used M$. ... intellisense and integrated debugger. ...
    (comp.lang.perl.misc)