develooper Front page | perl.perl5.porters | Postings from July 2016

Re: async/await syntax - call to action

Thread Previous
Paul "LeoNerd" Evans
July 1, 2016 21:33
Re: async/await syntax - call to action
Message ID:
On Fri, 1 Jul 2016 22:15:27 +0100
"Paul \"LeoNerd\" Evans" <> wrote:

> I would like this to be implemented by the code in 'supersize' (which
> I imagine would have to be an XS function) mutating the CVs stored in
> the &one, &five, and &ten globs themselves, so that any caller with
> any reference to these functions will observe the same result. It is
> further required that, if these so-modified functions are either
> exported, or stand as object methods, that other callers to these
> functions see the intended values (1, 5, 10) without themselves
> needing to be aware of supersize in any way.

I probably ought to add that it would be cheating to rely on the
trivially-small nature of these three given test functions. The
solution ought to be generic enough to cope with any function body,
because it should somehow hook itself dynamically "after" the return
value has been calculated and placed on the stack but before the
actual result has been transferred to the caller.

Paul "LeoNerd" Evans      |  |

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