News for hackers. Stuff that matters.
Re:Go: a nice language with an annoying personality by stcredzero on Friday January 18, 2013 @12:24PM (#5079744)
> It's documentation - that can be checked by the compiler for correctness.

Exactly. This was a convention used by Smalltalk shops. It came about because of the appearance of the Refactoring Browser, which caused a 10X increase in the rate and ease of refactoring. Before, Smalltalkers used to put snippets of code in comments with the exhortation to "run this" or "debug this" to clarify how a certain part of the API worked. The problem arose that refactorings would often break those snippets. However,

    false ifTrue: 
        ["Debug this"
        myObj := MyClass new.
        myObj myWonderfulMethod.].
...was very fast (it was a jump on many VMs) and would never break even if refactorings hit it.

There are no comments on this comment yet.