On Sat, Nov 30, 2013 at 7:55 PM, Tony Arcieri <[email protected]> wrote:
> On Fri, Nov 29, 2013 at 11:34 PM, Oren Ben-Kiki <[email protected]> wrote: > >> I find `do` syntax form is vital for DSL-ish code. >> > > On Sat, Nov 30, 2013 at 12:26 AM, Patrick Walton <[email protected]> > wrote: > >> The main reason for "do"'s existence is to make task spawning look nice. > > > I've got to say that the "do" syntax is one of the things that appeals to > me about Rust, and will probably appeal to the people that Steve Klabnik is > drawing to the language with Rust for Rubyists. > > It might seem like a small thing but the effects on the type of programs > you can write, it actually has a pretty profound effect, IMO. > > -- > Tony Arcieri > > I agree actually, I was using do to implement some convenience logic and my code went from: do function { someotherFunction() }; to function(|| someotherFunction()); Maybe I'm abusing something here, but I found the first format more intuitive and elegant... I know there's rumblings about io conditions going away, but the change also makes that more awkward... :/
_______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
