Open tmccombs opened 8 years ago
Right, I forgot to mention that it only works with character streams, and octets t overrides it.
Actually, I just thought of a way to add support for octet streams without too much effort, I'll add that to this pull request.
I won't merge any PRs without tests. :(
Please add test cases includes :stream stream
and :stream stream :octets t
.
And, it's better to me to rename keyword :stream
to :output
because stream can be input or output. :)
And, I saw PR in fast-io.
After this PR is merged, I will remove (fast-io::flush *stream*)
.
Hmmm, I need to update compile-encoder and the compiler macro as well.
I played around with it for a while, but eventually realized that the evals execute the code in a null lexical environment, which makes it difficult to capture the output stream. If you have any ideas on how to get compile-encoder to work with an output stream I would be happy to help implement it.
How about with
:octets t
?