[Pharo-users] Re: [vwnc] Block evaluation with n+1 arguments

2023-04-10 Thread Richard O'Keefe
>From the slides: "What is the difference between a block and a simple object understanding #value?" The slides give the wrong answer. The right answer is that - a block can see the variables of the blocks, method, and object containing it which allows ENCAPSULATION of long term and short te

[Pharo-users] Re: [vwnc] Block evaluation with n+1 arguments

2023-04-10 Thread Richard Sargent
Excellent write up, Stephane! I will add that over the years, there have been many times (countless!) when developing/debugging involved a complex block and that turned out to be significant nuisance. I can elaborate on the details, but once a block gets passed around, revising it on the fly b

[Pharo-users] Re: Block evaluation with n+1 arguments

2023-04-10 Thread Richard O'Keefe
(1) I have #value:valueWithArguments: in my personal library. (2) The way to answer your question is to look at #valueWithArguments:, It normally goes through a primitive. However, it *does* have backup code that you could adapt. (3) Without benchmarking, it's not clear whether the cost of