Skip Menu |

This queue is for tickets about the Exception-SEH CPAN distribution.

Report information
The Basics
Id: 59147
Status: stalled
Priority: 0/
Queue: Exception-SEH

People
Owner: Nobody in particular
Requestors: Dan [...] DWright.Org
Cc:
AdminCc:

Bug Information
Severity: Unimportant
Broken in: 0.0201
Fixed in: (no value)



Subject: Error when doing "try" on the same line as "use Exception::SEH"
This fails: # perl use Exception::SEH; try { 1 } PL_linestr not long enough, was Devel::Declare loaded soon enough in - at /usr/local/lib/perl5/site_perl/5.10.1/i386-freebsd/Exception/SEH/Parser.pm line 139. This works: # perl -MCarp::Always use Exception::SEH; try { 1 } It would seem that if you put the try on the same line as the use statement, you will get an error. That is probably not that big of a deal until you try using Exception::SEH in a one-liner: # perl -MCarp::Always -e ' use Exception::SEH; try{1} ' PL_linestr not long enough, was Devel::Declare loaded soon enough in -e at /usr/local/lib/perl5/site_perl/5.10.1/i386-freebsd/Exception/SEH/Parser.pm line 139 Exception::SEH::Parser::substitute('Exception::SEH::Parser=HASH(0x81923f0)', '(\@_, sub', 0) called at /usr/local/lib/perl5/site_perl/5.10.1/i386-freebsd/Exception/SEH/Parser.pm line 116 Exception::SEH::Parser::inject('Exception::SEH::Parser=HASH(0x81923f0)', '(\@_, sub') called at /usr/local/lib/perl5/site_perl/5.10.1/i386-freebsd/Exception/SEH.pm line 83 Exception::SEH::parse_try('try', 21) called at /usr/local/lib/perl5/site_perl/5.10.1/i386-freebsd/Devel/Declare.pm line 274 Devel::Declare::linestr_callback('const', 'try', 21) called at -e line 1 Note that a work-around solution to the one-liner is: # perl -MCarp::Always -MException::SEH -e 'try{1} ' So, all in all, this seems to be a very minor bug.
This is due to Devel::Declare one-liners handling, i can't solve this.