change typeset-code to conform to text:color<%>'s interface

The `typeset-code` function assumed that a lexeme must be `eof` on an
end-of-file, but `test:color<%>` allows it to be anything. Instead,
the check should be on type as 'eof.
impersonated mutator: fix internal stack overflow

This is not a new bug, but it was exposed by the interaction
of the changed to the impersonated-mutator protocol and
the `unstable/option` test suite.
unstable/options: fix for `chaperone-struct` change

Contrary to the comment for 0b71b8481d, the `unstable/options`
implementation used the first argument to a mutator wrapper.
Adjust to close over the wrapped value.
updated HISTORY.txt

merge to 6.1.1 release