Implement named blocks.

Closes #223.