[squeak-dev] Re: A question about block closures.

Klaus D. Witzel klaus.witzel at cobss.com
Wed Jul 8 17:19:25 UTC 2009


On Wed, 08 Jul 2009 18:55:28 +0200, Eliot Miranda wrote:

> As regards more generic property handling I don't know of a better way  
> than
> the doesNotUnderstand: handler for handling properties held in  
> per-instance
> dictionaries if the constraint is that you definitely don't want to  
> compile
> accessors for the property and you are using the vanilla VM.

I'm using this:

  (Object methodDict at: #aSymbol flushCache put: #name -> #value).
  (Object aSymbol)

and the VM then sends (in this example) to the Association

anAssociation>>run: #aSymbol with: #() in: Object

This is (AFAIK) from/for ObjectAsMethod in the "vanilla" VM. But beware,  
don't put a small int, then the VM crashes

- http://bugs.squeak.org/view.php?id=7157

/Klaus

...




More information about the Squeak-dev mailing list