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] Is there a Parsec equivalent in Rust?

2014-06-12 Thread Meredith L. Patterson
I have been meaning to write Rust bindings for Hammer ( https://github.com/UpstandingHackers/hammer), my C parser-combinator library which is loosely inspired by Parsec and gratuitously rips off Scala's packrat parser implementation. There is an issue open for it ( https://github.com/UpstandingHack

Re: [rust-dev] Struct members in trait definitions

2013-09-20 Thread Meredith L. Patterson
Hi Andres, I'm thinking about your question from a structural typing point of view, so let me see if an analogy from Scala (which has its own take on traits) helps. Scala is more of an OO language than Rust is, and Scala traits can extend classes (abstract or not), which is how it's possible for a