> True, but most of those other ways are either irrelevant to this example
> (i.e. make no difference to the existing behaviours) or they are sub-cases
> of the existing cases (which one might or might nor choose to optimize).
>

Yes, but how do I know that those other ways will continue to be irrelevant
in the future?

It would be nice if the wrapper subroutine could be writen in such a way
that
it can take advantage of any future context dependant
behaviours/optimizations
that are added to the wrapped subroutine without having to be revisited when
those behaviours/optimizations are added.

This might be more of a consideration where the two subroutines are
maintained
by different people than when they are maintained by the same person.

Might it be nice to be able to say something like

@ret = call_in_my_context &wrapped;

In situations like this?

William


Reply via email to