[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: [ANN] lazy.rb 0.9.5 -- transparent futures!

MenTaLguY

2/23/2006 12:04:00 AM

On Wed, 2006-02-22 at 14:14 -0800, Shashank Date wrote:
> Problem: All the promises I make, cannot have any arguments ! !

> So something like this is what I have in mind:
>
> x = promise("CUSTOMERS") { |table_name|
> long_running_query(table_name)}

Hmm. Would this work?

table_name = "CUSTOMERS"
x = promise { long_running_query(table_name) }

-mental