develooper Front page | perl.perl5.porters | Postings from June 2017

Re: Deprecation of ${^ENCODING}

Thread Previous | Thread Next
Sawyer X
June 9, 2017 08:43
Re: Deprecation of ${^ENCODING}
Message ID:

On 06/08/2017 07:43 PM, Father Chrysostomos wrote:
> Sawyer X wrote:
>> I think what this addresses is a developer assuming that undef'ing this
>> variable (by applying "undef" to it, undef()'ing it, or local()izing it)
>> has an effect. Any such assumption might be worthwhile verifying doesn't
>> work by fatalizing.
> The effect that
>     local ${^ENCODING} = undef;
> has is to protect code from buggy behaviour possibly turned on by some
> other piece of code.  Such defensive programming should continue to
> work, so that people *now* can write such code to make their new code
> work properly in older perl versions.

Pretty much sums up why it probably shouldn't be fatalized.

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About