Transcript is not thread-safe???

Jörn Eyrich Joern.Eyrich at brokat.com
Sat Oct 28 13:35:48 UTC 2000


Bob Arning wrote:
> 
> On Sat, 28 Oct 2000 01:51:00 -0500 jchludzinski at worldkey.net wrote:
> > ...
> >I hope there's NOTHING inherent in Morphic which makes it ill
> >suited for thread-safety???  Isn't Java's Swing (set) thread -
> >safe???
> ...
> The simple fact is that very little of Squeak or Smalltalk in general is designed with thread safety in mind. ...
> ...
> ... If one writes
> 
>         WorldState addDeferredUIMessage: [...some UI code...]
> 
> then the code in the block will be evaluated by the UI process at a safe point in the morphic world cycle ...

IIRC, Java's Swing and Morphic are rather similar in this matter, there are a few articles about using multiple threads with Swing at the java web site (the swing connection?), which also talk a bit about the rationale behind their design.

There's even an equivalent to addDeferredUIMessage:, called SwingUtil.invokeLater() or some such.

Joern





More information about the Squeak-dev mailing list