grantila / q

A platform-independent promise library for C++, implementing asynchronous continuations.
http://libq.io
Apache License 2.0
193 stars 24 forks source link

q fails to compile with VS 2017 15.6.2 #19

Closed nholthaus closed 6 years ago

nholthaus commented 6 years ago

Compilation fails with the following error:

C:\dev\q\libs\q\include\q\promise\impl\rest.hpp(141): error C2244: 'q::detail::generic_promise<B,T...>::forward': unable to match function definition to an existing declaration
  C:\dev\q\libs\q\include\q/promise/impl/rest.hpp(140): note: see declaration of 'q::detail::generic_promise<B,T...>::forward'
  C:\dev\q\libs\q\include\q/promise/impl/rest.hpp(141): note: definition
  C:\dev\q\libs\q\include\q/promise/impl/rest.hpp(141): note: 'std::enable_if<std::is_void<_V>::value&&q::detail::generic_promise<B,T...>::argument_types::empty::value,q::promise<U...>>::type q::detail::generic_promise<B,T...>::forward(U &&...)'
  C:\dev\q\libs\q\include\q/promise/impl/rest.hpp(141): note: existing declarations
  C:\dev\q\libs\q\include\q/promise/impl/rest.hpp(141): note: 'std::enable_if<std::is_void<_V>::value&&q::arguments<To...>::empty::value,q::promise<U...>>::type q::detail::generic_promise<B,T...>::forward(U &&...)'

It looks to me like a bug with the compilers namespace resolution, but I'll submit a small PR which fixes the issue.

grantila commented 6 years ago

How utterly crazy, but the PR looks good, thanks!