develooper Front page | perl.perl5.porters | Postings from February 2011

[perl #77384] Passing a ref to warn doesn't append file and line

Thread Next
From:
Father Chrysostomos via RT
Date:
February 20, 2011 14:30
Subject:
[perl #77384] Passing a ref to warn doesn't append file and line
Message ID:
rt-3.6.HEAD-24085-1298241045-869.77384-15-0@perl.org
With the hope of finally resolving this for 5.14:

I propose that we make warn() stringify the argument if there is not
$SIG{__WARN__} handler (and leave die() alone for now). It may not be
the ideal long-term solution, but it leaves Zefram’s
$SIG{__WARN__}-getting-a-reference in place, and restores the file and
line number to warnings (that happen to be references) most of the time.

The patch will probably be about two lines long.

Any thoughts?

(Since this is in the list of blockers [and has been ever since that
list was made], is it exempt from the ‘User-visible changes’ freeze?)

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About