2014/1/14 Kenneth Adam Miller
I figured out how to do it: filtering_ostream fos; fos.push(back_insert_device<string>(x));
[...]
On Tue, Jan 14, 2014 at 8:20 AM, Kenneth Adam Miller <
kennethadammiller@gmail.com> wrote:
I have an object for which operator << is defined, myobj.
I want to compress into a buffer, and I know that this can be done with boost. I would prefer a buffer that dynamically resizes, but that only allocates new space, preferably treating discontiguous space brought on by new allocations as though the whole buffer was one piece; I don't want to find that it's copying data at all. So vector won't work as a buffer; there's no need for it to be contiguous, just as fast as possible.
Hi,
Did you satisfy your "no copying" requirement? How? Was the requirement based only on performance concerns? Regards, Kris