Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no suitable userdefined conversion from #720

Open
kunoh opened this issue Mar 16, 2018 · 1 comment
Open

no suitable userdefined conversion from #720

kunoh opened this issue Mar 16, 2018 · 1 comment

Comments

@kunoh
Copy link

kunoh commented Mar 16, 2018

Severity Code Description Project File Line Suppression State
Error (active) E0312 no suitable user-defined conversion from "Concurrency::taskConcurrency::details::_BadContinuationParamType" to "Concurrency::task" exists Http_test c:\Users\heltbork\source\repos\Http_test\Http_test\Http_test.cpp 34

I'm basically just copy/pasted this example
https://github.com/Microsoft/cpprestsdk/wiki/Getting-Started-Tutorial

But this line is giving me problem
pplx::task requestTask = fstream::open_ostream(U("results.html")).then([=](ostream outFile)

Is there anything I could be missing? Or is this example broken?

@zhouguoguo
Copy link

I made following change and error is removed:

return concurrency::task<size_t>(response.body().read_to_end(fileStream->streambuf()));
//return response.body().read_to_end(fileStream->streambuf());

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants