Challenge 1: which Selector is chosen


#1

I was stumped on Challenge 1, but thanks to viewtopic.php?f=180&t=3648, I’ve got it working. However, I’m a bit confused on which “compare:” is getting called. Ordering on case-insensitive match (as listed in the book) makes sense as this is a method on NSString. However, “compare:” is not, at least not without more options (as I read the docs).

So, which class gets called when “compare:personName.length” is passed? I’ve been wandering the inheritance stack, but just don’t see it.

Thanks!


#2

I think i may have answered my own question here: viewtopic.php?f=180&t=3659&p=8338#p8338