Related to #56, #54, #34. Example compiles, does not work -- see inline comments.