develooper Front page | perl.perl5.porters | Postings from September 2012

Re: [perl #114536] Optimize assigning to scalars from @_

Thread Previous | Thread Next
From:
Aristotle Pagaltzis
Date:
September 2, 2012 09:01
Subject:
Re: [perl #114536] Optimize assigning to scalars from @_
Message ID:
20120902160117.GA8316@fernweh.plasmasturm.org
* Father Chrysostomos via RT <perlbug-followup@perl.org> [2012-08-31 23:15]:
> One thing you would have to be careful of is &foo-style calls, that
> share @_.
>
> XS modules can get the caller’s arguments via get_av("_"), and any sub
> call could potentially be an XS call.
>
> I don’t think this optimisation is possible.

Pardon my ignorance in perlguts, but as far as I can tell within the
reach of my understanding, David’s proposal changes absolutely nothing
about the semantics of @_ in any way whatsoever. I understood his call
to be for a way to do skip the usual “push push push list-assign” grind
required to implement `my ($foo, $bar, $baz) = @_` in terms of the
general-case implementation for assigning to a list – which would have
no effect I can see on the presence or contents etc of @_.

Were all of that correct, then the answer to your objections should seem
to be a simple – so what?

Is it? Am I missing something?

Regards,
-- 
Aristotle Pagaltzis // <http://plasmasturm.org/>

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