[MacRuby-devel] Key-Value Compliance & valueForKey:
jballanc at gmail.com
Thu Dec 22 07:49:11 PST 2011
Just wanted to follow up on this…did you manage to resolve the issue? If not, could you make sure you log this bug with Trac (https://www.macruby.org/trac/report)?
On Thursday, November 17, 2011 at 3:44 PM, Patrick Rogers wrote:
> Hi everyone,
> I'm trying to automatically generate the KVC-compliant methods for indexed to-many relationships.
> Here's my current attempt, https://gist.github.com/1374142, which borrows from hotcocoa's kvo_array (I couldn't get `kvo_array` to work and I wanted something that could just automatically be backed by an Array).
> Anyways, countOf<Key> and objectIn<Key>AtIndex: are both generated and work.
> However, when I try and use valueForKey(<key>) on my generated keys, MacRuby crashes with:
> > unknown: [BUG] unknown Objective-C immediate: 0x1 (nil)
> > MacRuby 0.11 (ruby 1.9.2) [universal-darwin10.0, x86_64]
> >  26123 abort macruby kvo_array.rb
> It is my understanding this should return an array based on my countOf<Key> and objectIn<Key>AtIndex: methods.
> On the other hand, when I use the manually defined methods, valueForKey(...) works as expected.
> Is there an issue with my code/approach or is this a MacRuby bug?
> MacRuby-devel mailing list
> MacRuby-devel at lists.macosforge.org (mailto:MacRuby-devel at lists.macosforge.org)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the MacRuby-devel