[squeak-dev] The Inbox: ST80-ct.256.mcz

K K Subbu kksubbu.ml at gmail.com
Sat Jun 13 11:57:59 UTC 2020


On 12/06/20 11:18 pm, Thiede, Christoph wrote:
> Marcel explicitly asked for duplicating these lines. However, one 
> single condition would not be bad either, but why would you use #| 
> instead of #or: here? Is this just in order to save one pair of 
> brackets? ;-)

It is an simple boolean expression that can be evaluated in a single 
sequence of bytecodes.

If the first part of the or: is false, then a block has to be activated 
and evaluated for the result. If the block involves significant 
computation then the overhead may not matter much. For simple 
expressions, it is an overkill.

Regards .. Subbu


More information about the Squeak-dev mailing list