[MacRuby-devel] What's happened to Dispatch::Job?
David Frantz
websterindustro at mac.com
Thu Jan 20 07:29:53 PST 2011
Ok, forgive me for this question as I'm not a practicing Ruby programmer but why would Dispatch not be part of Mac Ruby?
For those wondering why I've been hanging out here for the last couple of months it is due to the thought that Mac Ruby might become an officially supported platform for Mac development. So I'm trying to wrap my head around why people would use it (Ruby) instead of C/C++/Objective C or Python for that matter. Frankly I think I need convincing in another way so the next question is this, is there a good intro to Ruby that isn't oriented to web development? My interest in the web is close to zero and unfortunately most Ruby books seem to be focused there. Either that or my mind just isn't oriented to the Ruby way.
David A Frantz
websterindustro4at4mac.com
Sent from my iPhone.
On Jan 20, 2011, at 9:56 AM, Mark Rada <mrada at marketcircle.com> wrote:
> The dispatch library was removed from the core just before the 0.8 release. Someone is maintaining it as a gem.
>
> I thought the dispatch library only had the Enumerable module extensions, but I guess it had the Job class as well since I also don't have it (using a 0.9 nightly build).
>
> Someone who has better knowledge than me might be able to answer your questions more thoroughly.
>
>
> Mark Rada
> mrada at marketcircle.com
>
>
>
> On 2011-01-20, at 9:48 AM, Martin Hawkins wrote:
>
>> I was looking at the short intro to GCD in Matt's book 'Macruby - The
>> Definitive Guide'
>>
>> I have macruby 0.8 and I come across an immediate problem
>> macirb --simple-prompt
>>>> require 'dispatch'
>> LoadError: no such file to load -- dispatch
>>
>> However, it knows about Dispatch:
>> macirb --simple-prompt
>>>> @queue = Dispatch::Queue.new('a-queue-name')
>> => a-queue-name
>>
>> but it doesn't know about Job:
>> macirb --simple-prompt
>>>> job = Dispatch::Job.new { slow_operation }
>> NameError: uninitialized constant Dispatch::Job
>>
>> and, finally, the line on p24, 'To see the available concurrent
>> enumerable methods'
>> macruby -rdispatch -e "puts [].methods.grep(/^p_/)"
>> no such file to load -- dispatch (LoadError)
>> which, I suppose, just reiterates the first point.
>>
>> Is there an 'official' site where I can post queries regarding this
>> book?
>> _______________________________________________
>> MacRuby-devel mailing list
>> MacRuby-devel at lists.macosforge.org
>> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
>
> _______________________________________________
> MacRuby-devel mailing list
> MacRuby-devel at lists.macosforge.org
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
More information about the MacRuby-devel
mailing list