Hi,

I am trying to use lexical_cast to convert from strings to qvm vectors, but I keep getting an ambiguous operator>> error. I have overloaded the >> operator for istreams and that seems to be working fine when I use it to read from a istringstream. In a lexical_cast, though, I get the "ambiguous overload for operator>>" error. I have tried declaring my operator>> overload inside the std and boost::qvm namespaces to check if it was something related to ADL, but I keep getting the same error. The thing is the other candidates do not seem to make a lot of sense to me. Could somebody please tell me what I am doing wrong?

Thanks in advance,

Enrique Garcia

This is a minimal example (I am building gcc/boost from the last versions on their repositories):

#include <iostream>
#include <boost/qvm/vec.hpp>
#include <boost/lexical_cast.hpp>

std::ostream& operator<<(std::ostream& out, boost::qvm::vec<float, 3> const& v)
{
  out << "(" << v.a[0] << "," << v.a[1] << "," << v.a[2] << ")";
}

std::istream& operator>>(std::istream& in, boost::qvm::vec<float, 3>& v)
{
  char c;
  return in >> c >> v.a[0] >> c >> v.a[1] >> c >> v.a[2] >> c;
}

int main()
{
  boost::qvm::vec<float, 3> vect { 1.0f, 2.0f, 3.0f };
  std::cout << vect << std::endl;

  // This code works just fine. (4.0,5.0,6.0) is printed
  std::istringstream istream("(4.0,5.0,6.0");
  istream >> vect;
  std::cout << vect << std::endl;

  // This code generates an ambiguous overload for operator>> error (see below)
  vect = boost::lexical_cast<boost::qvm::vec<float, 3>>("(1.0,2.0,3.0)");
  std::cout << vect << std::endl;

  return 0;
}

This is the error I am getting from gcc:

In file included from /usr/local/include/boost/config.hpp:61:0,

from /usr/local/include/boost/static_assert.hpp:17,

from /usr/local/include/boost/qvm/static_assert.hpp:7,

from /usr/local/include/boost/qvm/vec.hpp:11,

from /home/kique/Documents/Bitflow2x/source/main.cpp:57:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp: In instantiation of 'const bool boost::detail::has_right_shift_impl::operator_exists<std::basic_istream<char>, boost::qvm::vec<float, 3> >::value':

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:179:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl1<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care, false>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:208:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:216:8: required from 'struct boost::has_right_shift<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:241:21: required from 'struct boost::detail::deduce_target_char_impl<boost::detail::deduce_character_type_later<boost::qvm::vec<float, 3> > >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:270:89: required from 'struct boost::detail::deduce_target_char<boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:407:92: required from 'struct boost::detail::lexical_cast_stream_traits<const char*, boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:468:15: required from 'struct boost::detail::lexical_converter_impl<boost::qvm::vec<float, 3>, const char*>'

/usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:196:44: required from 'bool boost::conversion::detail::try_lexical_convert(const Source&, Target&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/usr/local/include/boost/lexical_cast.hpp:41:60: required from 'Target boost::lexical_cast(const Source&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/home/kique/Documents/Bitflow2x/source/main.cpp:83:72: required from here

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:158:70: error: ambiguous overload for 'operator>>' (operand types are 'std::basic_istream<char>' and 'boost::qvm::vec<float, 3>')

BOOST_STATIC_CONSTANT(bool, value = (sizeof(s_check(((make<Lhs>() BOOST_TT_TRAIT_OP make<Rhs>()),make<has_operator>())))==sizeof(::boost::type_traits::yes_type)));

^

In file included from /usr/local/include/c++/7.0.0/iostream:40:0,

from /home/kique/Documents/Bitflow2x/source/main.cpp:56:

/usr/local/include/c++/7.0.0/istream:120:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__istream_type& (*)(std::basic_istream<_CharT, _Traits>::__istream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]

operator>>(__istream_type& (*__pf)(__istream_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:124:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__ios_type& (*)(std::basic_istream<_CharT, _Traits>::__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>; std::basic_istream<_CharT, _Traits>::__ios_type = std::basic_ios<char>]

operator>>(__ios_type& (*__pf)(__ios_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:131:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]

operator>>(ios_base& (*__pf)(ios_base&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:259:7: note: candidate: std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__streambuf_type*) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__streambuf_type = std::basic_streambuf<char>]

operator>>(__streambuf_type* __sb);

^~~~~~~~

In file included from /usr/local/include/boost/type_traits/has_right_shift.hpp:43:0,

from /usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:39,

from /usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:42,

from /usr/local/include/boost/lexical_cast.hpp:32,

from /home/kique/Documents/Bitflow2x/source/main.cpp:58:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:70:13: note: candidate: boost::detail::has_right_shift_impl::no_operator boost::detail::has_right_shift_impl::operator>>(const boost::detail::has_right_shift_impl::any&, const boost::detail::has_right_shift_impl::any&)

no_operator operator BOOST_TT_TRAIT_OP (const any&, const any&);

^~~~~~~~

In file included from /usr/local/include/c++/7.0.0/iostream:40:0,

from /home/kique/Documents/Bitflow2x/source/main.cpp:56:

/usr/local/include/c++/7.0.0/istream:808:5: note: candidate: std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, signed char*) [with _Traits = std::char_traits<char>]

operator>>(basic_istream<char, _Traits>& __in, signed char* __s)

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:803:5: note: candidate: std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, unsigned char*) [with _Traits = std::char_traits<char>]

operator>>(basic_istream<char, _Traits>& __in, unsigned char* __s)

^~~~~~~~

In file included from /usr/local/include/boost/config.hpp:61:0,

from /usr/local/include/boost/static_assert.hpp:17,

from /usr/local/include/boost/qvm/static_assert.hpp:7,

from /usr/local/include/boost/qvm/vec.hpp:11,

from /home/kique/Documents/Bitflow2x/source/main.cpp:57:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp: In instantiation of 'const bool boost::detail::has_right_shift_impl::operator_returns_void<std::basic_istream<char>, boost::qvm::vec<float, 3> >::value':

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:179:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl1<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care, false>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:208:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:216:8: required from 'struct boost::has_right_shift<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:241:21: required from 'struct boost::detail::deduce_target_char_impl<boost::detail::deduce_character_type_later<boost::qvm::vec<float, 3> > >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:270:89: required from 'struct boost::detail::deduce_target_char<boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:407:92: required from 'struct boost::detail::lexical_cast_stream_traits<const char*, boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:468:15: required from 'struct boost::detail::lexical_converter_impl<boost::qvm::vec<float, 3>, const char*>'

/usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:196:44: required from 'bool boost::conversion::detail::try_lexical_convert(const Source&, Target&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/usr/local/include/boost/lexical_cast.hpp:41:60: required from 'Target boost::lexical_cast(const Source&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/home/kique/Documents/Bitflow2x/source/main.cpp:83:72: required from here

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:95:114: error: ambiguous overload for 'operator>>' (operand types are 'std::basic_istream<char>' and 'boost::qvm::vec<float, 3>')

BOOST_STATIC_CONSTANT(bool, value = (sizeof(::boost::type_traits::yes_type)==sizeof(returns_void((make<Lhs>() BOOST_TT_TRAIT_OP make<Rhs>(),returns_void_t())))));

^

In file included from /usr/local/include/c++/7.0.0/iostream:40:0,

from /home/kique/Documents/Bitflow2x/source/main.cpp:56:

/usr/local/include/c++/7.0.0/istream:120:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__istream_type& (*)(std::basic_istream<_CharT, _Traits>::__istream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]

operator>>(__istream_type& (*__pf)(__istream_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:124:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__ios_type& (*)(std::basic_istream<_CharT, _Traits>::__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>; std::basic_istream<_CharT, _Traits>::__ios_type = std::basic_ios<char>]

operator>>(__ios_type& (*__pf)(__ios_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:131:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]

operator>>(ios_base& (*__pf)(ios_base&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:259:7: note: candidate: std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__streambuf_type*) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__streambuf_type = std::basic_streambuf<char>]

operator>>(__streambuf_type* __sb);

^~~~~~~~

In file included from /usr/local/include/boost/type_traits/has_right_shift.hpp:43:0,

from /usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:39,

from /usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:42,

from /usr/local/include/boost/lexical_cast.hpp:32,

from /home/kique/Documents/Bitflow2x/source/main.cpp:58:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:70:13: note: candidate: boost::detail::has_right_shift_impl::no_operator boost::detail::has_right_shift_impl::operator>>(const boost::detail::has_right_shift_impl::any&, const boost::detail::has_right_shift_impl::any&)

no_operator operator BOOST_TT_TRAIT_OP (const any&, const any&);

^~~~~~~~

In file included from /usr/local/include/c++/7.0.0/iostream:40:0,

from /home/kique/Documents/Bitflow2x/source/main.cpp:56:

/usr/local/include/c++/7.0.0/istream:808:5: note: candidate: std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, signed char*) [with _Traits = std::char_traits<char>]

operator>>(basic_istream<char, _Traits>& __in, signed char* __s)

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:803:5: note: candidate: std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, unsigned char*) [with _Traits = std::char_traits<char>]

operator>>(basic_istream<char, _Traits>& __in, unsigned char* __s)

^~~~~~~~

In file included from /usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:42:0,

from /usr/local/include/boost/lexical_cast.hpp:32,

from /home/kique/Documents/Bitflow2x/source/main.cpp:58:

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp: In instantiation of 'struct boost::detail::deduce_target_char_impl<boost::detail::deduce_character_type_later<boost::qvm::vec<float, 3> > >':

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:270:89: required from 'struct boost::detail::deduce_target_char<boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:407:92: required from 'struct boost::detail::lexical_cast_stream_traits<const char*, boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:468:15: required from 'struct boost::detail::lexical_converter_impl<boost::qvm::vec<float, 3>, const char*>'

/usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:196:44: required from 'bool boost::conversion::detail::try_lexical_convert(const Source&, Target&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/usr/local/include/boost/lexical_cast.hpp:41:60: required from 'Target boost::lexical_cast(const Source&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/home/kique/Documents/Bitflow2x/source/main.cpp:83:72: required from here

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:241:21: error: 'value' is not a member of 'boost::has_right_shift<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>'

>::type type;

^~~~

In file included from /usr/local/include/boost/qvm/static_assert.hpp:7:0,

from /usr/local/include/boost/qvm/vec.hpp:11,

from /home/kique/Documents/Bitflow2x/source/main.cpp:57:

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:243:13: error: 'value' is not a member of 'boost::detail::deduce_target_char_impl<boost::detail::deduce_character_type_later<boost::qvm::vec<float, 3> > >::result_t {aka boost::has_right_shift<std::basic_istream<char>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>}'

BOOST_STATIC_ASSERT_MSG((result_t::value || boost::has_right_shift<std::basic_istream<wchar_t>, T >::value),

^

In file included from /usr/local/include/boost/config.hpp:61:0,

from /usr/local/include/boost/static_assert.hpp:17,

from /usr/local/include/boost/qvm/static_assert.hpp:7,

from /usr/local/include/boost/qvm/vec.hpp:11,

from /home/kique/Documents/Bitflow2x/source/main.cpp:57:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp: In instantiation of 'const bool boost::detail::has_right_shift_impl::operator_exists<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3> >::value':

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:179:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl1<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care, false>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:208:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:216:8: required from 'struct boost::has_right_shift<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:243:13: required from 'struct boost::detail::deduce_target_char_impl<boost::detail::deduce_character_type_later<boost::qvm::vec<float, 3> > >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:270:89: required from 'struct boost::detail::deduce_target_char<boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:407:92: required from 'struct boost::detail::lexical_cast_stream_traits<const char*, boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:468:15: required from 'struct boost::detail::lexical_converter_impl<boost::qvm::vec<float, 3>, const char*>'

/usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:196:44: required from 'bool boost::conversion::detail::try_lexical_convert(const Source&, Target&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/usr/local/include/boost/lexical_cast.hpp:41:60: required from 'Target boost::lexical_cast(const Source&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/home/kique/Documents/Bitflow2x/source/main.cpp:83:72: required from here

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:158:70: error: ambiguous overload for 'operator>>' (operand types are 'std::basic_istream<wchar_t>' and 'boost::qvm::vec<float, 3>')

BOOST_STATIC_CONSTANT(bool, value = (sizeof(s_check(((make<Lhs>() BOOST_TT_TRAIT_OP make<Rhs>()),make<has_operator>())))==sizeof(::boost::type_traits::yes_type)));

^

In file included from /usr/local/include/c++/7.0.0/iostream:40:0,

from /home/kique/Documents/Bitflow2x/source/main.cpp:56:

/usr/local/include/c++/7.0.0/istream:120:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__istream_type& (*)(std::basic_istream<_CharT, _Traits>::__istream_type&)) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<wchar_t>]

operator>>(__istream_type& (*__pf)(__istream_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:124:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__ios_type& (*)(std::basic_istream<_CharT, _Traits>::__ios_type&)) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<wchar_t>; std::basic_istream<_CharT, _Traits>::__ios_type = std::basic_ios<wchar_t>]

operator>>(__ios_type& (*__pf)(__ios_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:131:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::ios_base& (*)(std::ios_base&)) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<wchar_t>]

operator>>(ios_base& (*__pf)(ios_base&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:259:7: note: candidate: std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__streambuf_type*) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__streambuf_type = std::basic_streambuf<wchar_t>]

operator>>(__streambuf_type* __sb);

^~~~~~~~

In file included from /usr/local/include/boost/type_traits/has_right_shift.hpp:43:0,

from /usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:39,

from /usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:42,

from /usr/local/include/boost/lexical_cast.hpp:32,

from /home/kique/Documents/Bitflow2x/source/main.cpp:58:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:70:13: note: candidate: boost::detail::has_right_shift_impl::no_operator boost::detail::has_right_shift_impl::operator>>(const boost::detail::has_right_shift_impl::any&, const boost::detail::has_right_shift_impl::any&)

no_operator operator BOOST_TT_TRAIT_OP (const any&, const any&);

^~~~~~~~

In file included from /usr/local/include/boost/config.hpp:61:0,

from /usr/local/include/boost/static_assert.hpp:17,

from /usr/local/include/boost/qvm/static_assert.hpp:7,

from /usr/local/include/boost/qvm/vec.hpp:11,

from /home/kique/Documents/Bitflow2x/source/main.cpp:57:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp: In instantiation of 'const bool boost::detail::has_right_shift_impl::operator_returns_void<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3> >::value':

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:179:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl1<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care, false>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:208:4: required from 'const bool boost::detail::has_right_shift_impl::trait_impl<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>::value'

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:216:8: required from 'struct boost::has_right_shift<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:243:13: required from 'struct boost::detail::deduce_target_char_impl<boost::detail::deduce_character_type_later<boost::qvm::vec<float, 3> > >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:270:89: required from 'struct boost::detail::deduce_target_char<boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:407:92: required from 'struct boost::detail::lexical_cast_stream_traits<const char*, boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:468:15: required from 'struct boost::detail::lexical_converter_impl<boost::qvm::vec<float, 3>, const char*>'

/usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:196:44: required from 'bool boost::conversion::detail::try_lexical_convert(const Source&, Target&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/usr/local/include/boost/lexical_cast.hpp:41:60: required from 'Target boost::lexical_cast(const Source&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/home/kique/Documents/Bitflow2x/source/main.cpp:83:72: required from here

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:95:114: error: ambiguous overload for 'operator>>' (operand types are 'std::basic_istream<wchar_t>' and 'boost::qvm::vec<float, 3>')

BOOST_STATIC_CONSTANT(bool, value = (sizeof(::boost::type_traits::yes_type)==sizeof(returns_void((make<Lhs>() BOOST_TT_TRAIT_OP make<Rhs>(),returns_void_t())))));

^

In file included from /usr/local/include/c++/7.0.0/iostream:40:0,

from /home/kique/Documents/Bitflow2x/source/main.cpp:56:

/usr/local/include/c++/7.0.0/istream:120:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__istream_type& (*)(std::basic_istream<_CharT, _Traits>::__istream_type&)) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<wchar_t>]

operator>>(__istream_type& (*__pf)(__istream_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:124:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__ios_type& (*)(std::basic_istream<_CharT, _Traits>::__ios_type&)) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<wchar_t>; std::basic_istream<_CharT, _Traits>::__ios_type = std::basic_ios<wchar_t>]

operator>>(__ios_type& (*__pf)(__ios_type&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:131:7: note: candidate: std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::ios_base& (*)(std::ios_base&)) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<wchar_t>]

operator>>(ios_base& (*__pf)(ios_base&))

^~~~~~~~

/usr/local/include/c++/7.0.0/istream:259:7: note: candidate: std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__streambuf_type*) [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; std::basic_istream<_CharT, _Traits>::__streambuf_type = std::basic_streambuf<wchar_t>]

operator>>(__streambuf_type* __sb);

^~~~~~~~

In file included from /usr/local/include/boost/type_traits/has_right_shift.hpp:43:0,

from /usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:39,

from /usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:42,

from /usr/local/include/boost/lexical_cast.hpp:32,

from /home/kique/Documents/Bitflow2x/source/main.cpp:58:

/usr/local/include/boost/type_traits/detail/has_binary_operator.hpp:70:13: note: candidate: boost::detail::has_right_shift_impl::no_operator boost::detail::has_right_shift_impl::operator>>(const boost::detail::has_right_shift_impl::any&, const boost::detail::has_right_shift_impl::any&)

no_operator operator BOOST_TT_TRAIT_OP (const any&, const any&);

^~~~~~~~

In file included from /usr/local/include/boost/qvm/static_assert.hpp:7:0,

from /usr/local/include/boost/qvm/vec.hpp:11,

from /home/kique/Documents/Bitflow2x/source/main.cpp:57:

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp: In instantiation of 'struct boost::detail::deduce_target_char_impl<boost::detail::deduce_character_type_later<boost::qvm::vec<float, 3> > >':

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:270:89: required from 'struct boost::detail::deduce_target_char<boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:407:92: required from 'struct boost::detail::lexical_cast_stream_traits<const char*, boost::qvm::vec<float, 3> >'

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:468:15: required from 'struct boost::detail::lexical_converter_impl<boost::qvm::vec<float, 3>, const char*>'

/usr/local/include/boost/lexical_cast/try_lexical_convert.hpp:196:44: required from 'bool boost::conversion::detail::try_lexical_convert(const Source&, Target&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/usr/local/include/boost/lexical_cast.hpp:41:60: required from 'Target boost::lexical_cast(const Source&) [with Target = boost::qvm::vec<float, 3>; Source = char [14]]'

/home/kique/Documents/Bitflow2x/source/main.cpp:83:72: required from here

/usr/local/include/boost/lexical_cast/detail/converter_lexical.hpp:243:13: error: 'value' is not a member of 'boost::has_right_shift<std::basic_istream<wchar_t>, boost::qvm::vec<float, 3>, boost::detail::has_right_shift_impl::dont_care>'

BOOST_STATIC_ASSERT_MSG((result_t::value || boost::has_right_shift<std::basic_istream<wchar_t>, T >::value),

^

ninja: build stopped: subcommand failed.