[MacRuby] #1172: Function pointer fields in structs do not accept procs

MacRuby ruby-noreply at macosforge.org
Sun Feb 27 20:50:19 PST 2011


#1172: Function pointer fields in structs do not accept procs
----------------------------------------+-----------------------------------
 Reporter:  vincent.isambart@…          |       Owner:  lsansonetti@…        
     Type:  defect                      |      Status:  new                  
 Priority:  major                       |   Milestone:  MacRuby 1.0          
Component:  MacRuby                     |    Keywords:                       
----------------------------------------+-----------------------------------
 The following code should work without error:
 {{{
 framework 'Cocoa'
 callbacks = CGPatternCallbacks.new
 callbacks.drawPattern = proc { }
 }}}
 However it currently raises an error:
 {{{
 TypeError: expected instance of Pointer, got `#<Proc:0x200b1b0c0>' (Proc)
 }}}

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



More information about the macruby-tickets mailing list