Smalltalk offers a way to send multiple messages to the same receiver using a semicolon (;). This is called the cascade in Smalltalk jargon.
Expression Msg1 ; Msg2
Transcript show: 'Squeak is '. Transcript show: 'fun '. Transcript cr.
is equivalent to:
Transcript show: 'Squeak is'; show: 'fun '; cr
Note that the object receiving the cascaded messages can itself be the result of a message send. In fact the receiver of all the cascaded messages is the receiver of the first message involved in a cascade. In the following example, the first cascaded message is
setX:setY since it is followed by a cascade. The receiver of the cascaded message
setX:setY: is the newly created point resulting from the evaluation of
Point new, and not
Point. The subsequent message
isZero is sent to that same receiver.
Point new setX: 25 setY: 35; isZero → false