Re: [rust-dev] Is there a Parsec equivalent in Rust?

2014-06-13 Thread Meredith L. Patterson
That seems a bit excessive. C doesn't have higher-kinded types or monads either, *and* it's strict, but we cloned Parsec effectively enough. Neither parser combinators nor PEG/packrat *require* monads, or even lazy evaluation for that matter; they're just easier to implement that way. You can even

Re: [rust-dev] self/mut self in traits considered harmful(?)

2014-06-13 Thread Tommi
The problem: Chained calls to certain operators such as binary `*` and `+` may cause unnecessary memory allocations. For example: struct Vector { coordinates: Vecint } impl Mulint, Vector for Vector { fn mul(self, rhs: int) - Vector { let mut new_coordinates =

Re: [rust-dev] self/mut self in traits considered harmful(?)

2014-06-13 Thread Tommi
On 2014-06-13, at 13:14, Tommi rusty.ga...@icloud.com wrote: pub trait MulRHS, Result { fn mul(stable self, rhs: RHS) - Result; } Note: any other syntax for marking `self` as `stable` would be illegal. Although, I could see this kind of syntax being allowed as well: pub trait MulRHS,

Re: [rust-dev] Preserving formatting for slice's Show impl

2014-06-13 Thread Kevin Ballard
I would not expect this to be “mapped” over the slice. I encourage you to come up with an appropriate syntax to describe that and submit an RFC, although I wonder how you plan on dealing with things like key vs value in Maps, and further nesting (e.g. slices of slices, etc). As for applying it

Re: [rust-dev] self/mut self in traits considered harmful(?)

2014-06-13 Thread Patrick Walton
I have filed RFC #118 for this: https://github.com/rust-lang/rfcs/pull/118 Patrick ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev

[rust-dev] Nightly docs for Dash

2014-06-13 Thread Valerii Hiora
Hi, Being a big fan of offline documentation I've prepared a fresh docset for Dash (zeal, helm-dash, any other compatible software). Here is the link for subscription: dash-feed://https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fnet.vhbit.rust-doc%2FRustNightly.xml It's a beta and has a

Re: [rust-dev] Nightly docs for Dash

2014-06-13 Thread Clark Gaebel
Whoa this is cool stuff. I'll have you know it's useful to at least one person! - Clark On Fri, Jun 13, 2014 at 9:55 PM, Valerii Hiora valerii.hi...@gmail.com wrote: Hi, Being a big fan of offline documentation I've prepared a fresh docset for Dash (zeal, helm-dash, any other