[MacRuby] #1000: Xcode fails to load bridgesupport file automatically for user created framework
MacRuby
ruby-noreply at macosforge.org
Wed Nov 17 13:50:07 PST 2010
#1000: Xcode fails to load bridgesupport file automatically for user created
framework
----------------------------------+-----------------------------------------
Reporter: al_skipp@… | Owner: lsansonetti@…
Type: defect | Status: closed
Priority: blocker | Milestone: MacRuby 0.8
Component: MacRuby | Resolution: fixed
Keywords: bridgesupport |
----------------------------------+-----------------------------------------
Old description:
> When linking to a framework that includes a bridgesupport file, it is
> necessary to explicitly call 'load_bridge_support_file' with the path to
> the file.
>
> Included is a very simple framework that defines one class (TestBlock)
> with one method:
>
> - (void)callBlock:(void (^)())block;
>
> If the framework is included in a project it is possible to create a
> 'TestBlock' object within macruby, but calling the method 'callBlock',
> will fail. eg
>
> b = TestBlock.new
> b.callBlock( Proc.new {puts "hello from ruby"} ) #fails
>
> The code will succeed if 'load_bridge_support_file' is used first.
New description:
When linking to a framework that includes a bridgesupport file, it is
necessary to explicitly call 'load_bridge_support_file' with the path to
the file.
Included is a very simple framework that defines one class (TestBlock)
with one method:
{{{
- (void)callBlock:(void (^)())block;
}}}
If the framework is included in a project it is possible to create a
'TestBlock' object within macruby, but calling the method 'callBlock',
will fail. eg
{{{
b = TestBlock.new
b.callBlock( Proc.new {puts "hello from ruby"} ) #fails
}}}
The code will succeed if 'load_bridge_support_file' is used first.
--
Comment(by martinlagardette@…):
Same here:
{{{
$> macirb --simple-prompt
>> framework './BlockFrameworkTest.framework'
=> true
>> b = TestBlock.new
=> #<TestBlock:0x200c7a260>
>> b.callBlock Proc.new { puts 42 }
2010-11-17 22:49:16.031 macruby[9858:903] block: <__NSStackBlock__:
0x7fff5fbf8350>
42
=> #<TestBlock:0x200c7a260>
>> MACRUBY_VERSION
=> "0.8"
>> MACRUBY_REVISION
=> "svn revision 4894 from
http://svn.macosforge.org/repository/ruby/MacRuby/trunk"
>>
}}}
What version of MacRuby are you using?
--
Ticket URL: <http://www.macruby.org/trac/ticket/1000#comment:3>
MacRuby <http://macruby.org/>
More information about the macruby-tickets
mailing list