gh-667

This closes #667. `@index` and `@key` references refer to the current index/property when inside an 'each section (`{{#each foo}}..{{/each}}`) in handlebars mode.

It works by identifying those references at parse time and adding an index reference to the section, rather than identifying the index reference at render time. This is simpler, and prevents a class of bugs relating to e.g. reassignments that we'd probably have to deal with otherwise.