[MacRuby-devel] [MacRuby] #659: ER: Calling #== on an Obj-C object calls -isEqual:

MacRuby ruby-noreply at macosforge.org
Mon Apr 19 20:40:12 PDT 2010


#659: ER: Calling #== on an Obj-C object calls -isEqual:
---------------------------------------+------------------------------------
 Reporter:  joshua.ballanco@…          |       Owner:  lsansonetti@…        
     Type:  defect                     |      Status:  new                  
 Priority:  blocker                    |   Milestone:                       
Component:  MacRuby                    |    Keywords:                       
---------------------------------------+------------------------------------
 It would be nice if calling #== on an Obj-C object which defines -isEqual:
 used this method instead of doing a straight pointer comparison:
 {{{
 framework 'Foundation'

 a = NSDate.dateWithNaturalLanguageString('today')
 b = NSDate.dateWithNaturalLanguageString('today')
 if a == b
   p :ok
 elsif a.isEqual(b)
   p :ko
 end
 }}}

-- 
Ticket URL: <http://www.macruby.org/trac/ticket/659>
MacRuby <http://macruby.org/>



More information about the MacRuby-devel mailing list