Issue #27. Pass 2. Compilation succeeds, various runtime bugs remain to be vetted.