Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#309 perldl doesn't print stacktrace from barf

closed-fixed
core (120)
1
2013-03-22
2012-07-16
Chris Marshall
No

The problem is that the behavior of $@ and its
XS equivalents G_EVAL|G_KEEPERR have changed
as of perl version 5.14.0. The code works and shows
the traceback for perl 5.10.1 on cygwin:

pdl> sub t { barf "uh-oh" }

pdl> t
uh-oh at (eval 161) line 4
main::t() called at (eval 163) line 4
main::__ANON__() called at /usr/local/bin/perldl line 666
eval {...} called at /usr/local/bin/perldl line 666
main::eval_and_report('t\x{a}') called at /usr/local/bin/perldl line 604
main::process_input() called at /usr/local/bin/perldl line 624
eval {...} called at /usr/local/bin/perldl line 624

while for perl 5.16.0 with SPP (Strawberry Perl Portable):

pdl> sub t { barf "uh-oh" }

pdl> t

and, yes, there is no error or message of any sort.
I'm putting this in as a placeholder. If you need
more up-to-date exception handling, please install
Devel::REPL and use the new pdl2 shell instead
of the legacy perldl one.

Discussion

  • Chris Marshall
    Chris Marshall
    2012-11-13

    Bug fixed in Git.
    Thanks for reporting the problem!

     
  • Chris Marshall
    Chris Marshall
    2012-11-13

    F:\chm\perl\strawberry>perldl
    perlDL shell v1.354_001
    PDL comes with ABSOLUTELY NO WARRANTY. For details, see the file
    'COPYING' in the PDL distribution. This is free software and you
    are welcome to redistribute it under certain conditions, see
    the same file for details.
    ReadLines, NiceSlice, MultiLines enabled
    Reading PDL/default.pdl...
    Found docs database F:/chm/perl/strawberry/spp_5161/perl/site/lib/PDL/pdldoc.db
    Type 'help' for online help
    Type 'demo' for online demos
    Loaded PDL v2.4.11_001 (supports bad values)

    Note: AutoLoader not enabled ('use PDL::AutoLoader' recommended)

    pdl> sub t { barf "uh-oh" }

    pdl> t

    pdl> q

    F:\chm\perl\strawberry>perl spp_5161\perldl
    perlDL shell v1.355
    PDL comes with ABSOLUTELY NO WARRANTY. For details, see the file
    'COPYING' in the PDL distribution. This is free software and you
    are welcome to redistribute it under certain conditions, see
    the same file for details.
    ReadLines, NiceSlice, MultiLines enabled
    Reading PDL/default.pdl...
    Found docs database F:/chm/perl/strawberry/spp_5161/perl/site/lib/PDL/pdldoc.db
    Type 'help' for online help
    Type 'demo' for online demos
    Loaded PDL v2.4.11_001 (supports bad values)

    Note: AutoLoader not enabled ('use PDL::AutoLoader' recommended)

    pdl> sub t { barf "uh-oh" }

    pdl> t
    uh-oh at (eval 85) line 4.
    main::t() called at (eval 86) line 4
    main::__ANON__() called at spp_5161\perldl line 668
    eval {...} called at spp_5161\perldl line 668
    main::eval_and_report('t\x{a}') called at spp_5161\perldl line 604
    main::process_input() called at spp_5161\perldl line 624
    eval {...} called at spp_5161\perldl line 624

     
  • Chris Marshall
    Chris Marshall
    2012-11-13

    • assigned_to: nobody --> zowie
    • status: open --> pending-fixed
     
  • Chris Marshall
    Chris Marshall
    2013-03-22

    Bug fixed in Git.
    Thanks for reporting the problem!

     
  • Chris Marshall
    Chris Marshall
    2013-03-22

    • status: pending-fixed --> closed-fixed