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

error: redundant move in return statement #138

Closed
jc200 opened this issue Apr 25, 2016 · 2 comments
Closed

error: redundant move in return statement #138

jc200 opened this issue Apr 25, 2016 · 2 comments

Comments

@jc200
Copy link

jc200 commented Apr 25, 2016

Building the cpp rest sdk in Debug mode on OS X and received following 3 errors.
Below is one of them:

.../casablanca/Release/src/http/common/http_helpers.cpp:275:16: error
redundant move in return statement [-Werror, -Wredundant-move]
return std::move(src);

.../casablanca/Release/src/http/common/http_helpers.cpp:275:16: note:
remove std::move call here
return std::move(src);

@arkbriar
Copy link

I have just built successfully by removing the first "-Wall" in casablanca/Release/CMakeLists.txt, line 141

set(WARNINGS "-Wall -Wextra -Wcast-qual -Wconversion -Wformat=2 -Winit-self -Winvalid-pch -Wmissing-format-attribute -Wmissing-include-dirs -Wpacked -Wredundant-decls")

And a better approach is to merge the pr #140

@ras0219-msft
Copy link
Contributor

This is fixed in the development branch. Additionally, in the development branch we have a WERROR cmake option that you could disable which should also fix the build issue. (-DWERROR=0).

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

No branches or pull requests

3 participants