Pergunta

After finding the answer to How to return an fstream (C++0x), I was now wondering if there is a current c++0x library that implements move (or even swap) for fstreams (as gcc (27.9) does not). I'd prefer if it was free also.

Or is there any other way return to fstreams from functions by value?

I've tried compiling libcxx but it seems very linux/mac specific, and I need it to run on Solaris also, which it wouldn't compile on.

I can work around this issue (return by reference for example), but I thought I'd ask this just in case there was a solution that doesn't involve modifying the calling code.

Foi útil?

Solução

I believe Dinkumware sells a version of the C++ Standard Library with movable streams, but be sure to check it first.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top