Re-implement change of IO::Handle encoding.
Re-implement change of IO::Handle encoding.

Allowing a type object to be passed to indicate "no encoding", and
making an argument of 'bin' translate into that.

The most common use for this is a switch of encoding prior to doing
any I/O, but when passing it at `open` time is not an option. For all
other cases, we try to cope. Binary mode to having an encoding is the
straightforward case. Char mode to binary mode needs to "un-read" any
content in the decode buffer, and for now will only be allowed on a
handle that supports `seek`. Char mode to char mode with a different
encoding takes the bytes unused by the previous decoder and gives them
to the new one. In both of these cases, it's only generally safe to do
this after a control character (like a newline), otherwise bytes may
be hanging around inside of decode/normalization buffers if switching
away from, say, UTF-8. (This is not a change of behavior; in fact, we
allow *more* than we used to, given we get a couple of newly passing
tests.)

awwaiid/rakudo,raydiak/rakudo,lucasbuchala/rakudo,usev6/rakudo,Gnouc/rakudo,awwaiid/rakudo,Gnouc/rakudo,rakudo/rakudo,salortiz/rakudo,labster/rakudo,softmoth/rakudo,softmoth/rakudo,tbrowder/rakudo,tbrowder/rakudo,labster/rakudo,raydiak/rakudo,MasterDuke17/rakudo,raydiak/rakudo,lucasbuchala/rakudo,salortiz/rakudo,softmoth/rakudo,salortiz/rakudo,usev6/rakudo,sjn/rakudo,tony-o/rakudo,lucasbuchala/rakudo,Gnouc/rakudo,nbrown/rakudo,salortiz/rakudo,raydiak/rakudo,MasterDuke17/rakudo,MasterDuke17/rakudo,lucasbuchala/rakudo,salortiz/rakudo,tony-o/rakudo,tony-o/rakudo,tbrowder/rakudo,MasterDuke17/rakudo,labster/rakudo,nbrown/rakudo,sjn/rakudo,lucasbuchala/rakudo,labster/rakudo,Gnouc/rakudo,jonathanstowe/rakudo,nbrown/rakudo,jonathanstowe/rakudo,labster/rakudo,nbrown/rakudo,rakudo/rakudo,tony-o/rakudo,rakudo/rakudo,awwaiid/rakudo,sjn/rakudo,tony-o/rakudo,tbrowder/rakudo,softmoth/rakudo,tbrowder/rakudo,Gnouc/rakudo,awwaiid/rakudo,rakudo/rakudo,jonathanstowe/rakudo,usev6/rakudo,tony-o/rakudo,nbrown/rakudo,MasterDuke17/rakudo,softmoth/rakudo,rakudo/rakudo,nbrown/rakudo,sjn/rakudo,salortiz/rakudo,MasterDuke17/rakudo,Gnouc/rakudo,labster/rakudo,rakudo/rakudo,sjn/rakudo,awwaiid/rakudo,tbrowder/rakudo,jonathanstowe/rakudo,jonathanstowe/rakudo,usev6/rakudo,usev6/rakudo