I'll be brief: I have this piece of code:
QByteArray MyNBT::decompressData(QByteArray data)
{
filtering_streambuf<input> in;
std::string _data = data.data();
in.push( gzip_decompressor() );
in.push( boost::iostreams::back_inserter(_data) );
//in.push( std::back_inserter(_data) );
std::stringstream _sstream;
boost::iostreams::copy(in, _sstream);
QByteArray out = _sstream.rdbuf()->str().c_str();
return out;
}
And it gives an error at this line(s):
in.push( boost::iostreams::back_inserter(_data) );
//in.push( std::back_inserter(_data) );
The error is:
/usr/include/boost/iostreams/chain.hpp:244: error: invalid application of 'sizeof' to incomplete type 'boost::STATIC_ASSERTION_FAILURE<false>'
BOOST_STATIC_ASSERT((is_convertible<category, Mode>::value));
^
The compiler throws this error once in std::back_inserter(_data)
and twice with boost's one.
Thanks in advance.