in reply to (Segfault) Re: is_constant() - a routine that detects constant subs
in thread is_constant() - a routine that detects constant subs

Yup, I get the segfault too - Perl 5.6.1 on Linux. Very strange. I'm compiling bleadperl now; maybe it's already been fixed?

-sam

  • Comment on Re: (Segfault) Re: is_constant() - a routine that detects constant subs

Replies are listed 'Best First'.
Re: Re: (Segfault) Re: is_constant() - a routine that detects constant subs
by samtregar (Abbot) on May 19, 2002 at 21:37 UTC
    Argh. Not only is it not fixed in bleadperl, but I think bleadperl also has a bug. Check out the output using bleadperl:

    $ ./perl ~/crash.pl Constant subroutine One::FOO redefined at /home/sam/crash.pl line 59. Yes Constant subroutine One::FOO redefined at /home/sam/crash.pl line 59. Yes Segmentation fault (core dumped)

    So, not only is it segfaulting, but it's also printing warnings even when "no warnings" is in effect! Argh!

    -sam

      According to Rafael Garcia-Suarez this is actually a deliberate change. Overwriting a constant sub is now a mandatory warning in 5.7.3. Ho hum. So now I'll just catch both errors with $SIG{__WARN__} instead of the first.

      -sam