develooper Front page | perl.perl5.porters | Postings from December 2019

Re: @_ Suppression

Thread Previous | Thread Next
From:
Zefram via perl5-porters
Date:
December 2, 2019 13:56
Subject:
Re: @_ Suppression
Message ID:
20191202135640.vjmafnwmzsf6qxh7@fysh.org
Dave Mitchell wrote:
>    @_ will not be set, unset or localised on entry to or exit from
>    a signatured sub;

Bad idea.  Having a warning for recognisable use of @_ is better than
nothing, but according to decisions we already made it's not enough.
Way back, we determined that detection of the use of @_ wouldn't
be sufficiently complete to serve as the trigger for @_ suppression.
The reasons for that decision haven't changed.  It is right that we paid
attention to that issue in repeated decisions that we would not tie @_
suppression to signatures.  Nothing in the rationale for those decisions
has changed either.

@_ suppression should be controlled by means orthogonal to signatures,
probably a per-sub attribute (which can turn suppression either on or off)
with a lexical feature flag setting a default.  Default suppression can
become part of a feature bundle.

-zefram

Thread Previous | 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