News for hackers. Stuff that matters.
Re:Rust is surprisingly expressive by klodolph on Monday December 30, 2013 @03:20AM (#6983668)
And what would the definition of `editable?` look like?

    fn editable(&self) -> bool {
        self.created_at < 5.minutes().ago()
    }
Yes, it's wrong. No amount of unit testing or isolation is going to change the fact that whenever you read code like that, your brain will come up with two conflicting meanings, because these cutesy methods make it look too much like English, and English has different rules.

English parse tree is: ((less than (five minutes)) ago), whereas code parse tree is (less than ((five minutes) ago)).

There are no comments on this comment yet.