News for hackers. Stuff that matters.
Re:A Week with Mozilla's Rust by pitterpatter on Wednesday August 21, 2013 @06:09PM (#6253636)
>but I doubt Rust has something like this.

Oh, but it does! There's the cond! macro:

    let computed_key = cond!(
        (key.len() > self.block_size) { self.zero_pad(self.hash(key).digest) }
        (key.len() < self.block_size) { self.zero_pad(key) }
        _                             { key }
    );

There are no comments on this comment yet.