[MacRuby] #763: HotCocoa does not work with MacRuby Trunk.
MacRuby
ruby-noreply at macosforge.org
Tue Aug 24 17:07:38 PDT 2010
#763: HotCocoa does not work with MacRuby Trunk.
----------------------------------+-----------------------------------------
Reporter: watson1978@… | Owner: lsansonetti@…
Type: defect | Status: new
Priority: blocker | Milestone:
Component: MacRuby | Keywords: 0.7-blocker
----------------------------------+-----------------------------------------
Comment(by martinlagardette@…):
Reduction:
{{{
#!ruby
class A
attr_reader :delegate
def add_delegated_method
@delegate = Object.new
eval %{
def delegate.someFunction; end
}
end
end
A.new.add_delegated_method
}}}
Funny enough, this doesn't crash:
{{{
#!ruby
class A
def add_delegated_method
delegate = Object.new
eval %{
def delegate.someFunction; end
}
end
end
A.new.add_delegated_method
}}}
Apparently a problem in the resolution of `delegate` when defining the
method I would guess? It crashes when it uses the class getter, it works
with the block variable.
Evaling to something like `p delegate` works, it's really defining a
method that doesn't work.
--
Ticket URL: <http://www.macruby.org/trac/ticket/763#comment:2>
MacRuby <http://macruby.org/>
More information about the macruby-tickets
mailing list