show bytecodes?

tim Rowledge tim at rowledge.org
Sun Oct 14 01:14:36 UTC 2007


On 13-Oct-07, at 3:55 PM, Robert Withers wrote:

> The problem I perceive I have is when we have (4 + 5 eventual).   
> There is nothing that intercepts it.

Err. 4 + {some not-integer-not-float} will fail. It will get trapped  
in the prim failure code for SmallInteger>+ and the {some not-integer- 
not-float} will be sent #adaptToInteger:andSend: which rather  
usefully includes both the original 5 and the #+ selector. Seems like  
a perfect opportunity to build a promise and return it, no?

That looks like intercepting your problem to me, how about you? I  
think you're probably making this far more complex than it needs to be.

tim
--
tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
Useful random insult:- He has a tenuous grip on the obvious.





More information about the Squeak-dev mailing list