Monthly Archives: October 2007

Parsing Complex Comparisons

An interesting tidbit: can your programming language parse a < b < c? Perl can’t. Ruby can, but returns an error “undefined method `>’ for false:FalseClass.” Interestingly, Python accepts it, and even gives the correct result. Something clever must be going on in … Continue reading

Posted in Programming | Tagged , | 2 Comments

code.nytimes.com

A cool new site, with the best possible slogan, “All the code that’s fit to printf().” Nice to see a giant media company getting into this.

Posted in Programming | Tagged | Leave a comment

Why Doesn’t My Rails App Use memcached with cached_model?

Answer: you’re using the latest version of Rails (1.2.3), which slightly changes the syntax of its SQL statements. cached_model relies on a regular expression to match that SQL statement. To fix: Dive into the source of the cached_model gem, find … Continue reading

Posted in Programming | Tagged , | Leave a comment