Add reset to macro context
As discussed in #529 (closed) we need a way to reset the macro context. A .reset
is the most obvious:
syntax m = ctx => {
ctx.next('expr'); // foo + bar
// oops, just wanted one token
ctx.reset();
let {value} = ctx.next(); // foo
//...
}
m foo + bar
Other possible names:
.clear
.revert
.rewind