Potential bug in becomeForward:, need help!

Chris Muller afunkyobject at yahoo.com
Fri May 17 05:16:44 UTC 2002


> Bob Arning wrote:
>.. What's happening is that the pointer to String new is 
>replaced with a pointer to #MyTestClass as you would expect, but the hash
value is 
>copied from the old String new header to the #MyTestClass header ..

Rats.  Ok, so a potential override I could make in Smalltalk might be:

 - um, before my "super becomeForward:", trace pointers to the argument back 2
or 3 levels to see if its referenced by a hashed collection.  Save these into a
temp (ouch, that may require an allocation) that we can do: [ each rehash ]
afterward.

Ehh, do you think it would work?  For added safety, maybe it would be worth the
cost to verify what we find respondsTo: #rehash..

Regards,
  Chris


__________________________________________________
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com



More information about the Squeak-dev mailing list