[MacRuby-devel] MacRuby 0.5b1: Tinkering with -[NSObject hash]
illenberger at mac.com
Mon Nov 16 14:17:49 PST 2009
I filed it as Ticket #437.
Am 15.11.2009 um 03:53 schrieb Laurent Sansonetti:
> Hi Frank,
> Thanks for the report, it looks like a critical bug in MacRuby. Could you file a bug report on Trac? This way we won't forget it for the upcoming release.
> On Nov 13, 2009, at 6:16 AM, Frank Illenberger wrote:
>> Hi everybody,
>> I just found out the hard way, that initializing the MacRuby runtime seems to alter the values returned by -[NSObject hash] even for objects of non-ruby classes. In my Objective-C application, I am loading the MacRuby runtime lazily once the user needs to load a Ruby plug-in. This immediately destroys all NSDictionaries/NSMapTables/NSSets that have been filled with objects before the loading.
>> The only workaround I have found so far, is to call -[MacRuby sharedRuntime] early at the start of the application, but this results in an unnecessarily slower startup time and a larger memory footprint.
>> Is the change in the hash values meant by design or might it be a bug in MacRuby?
More information about the MacRuby-devel