Module: Mesa
Branch: master
Commit: 2859c49f7b229db4a37b7c10fab739dbc96922cd
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=2859c49f7b229db4a37b7c10fab739dbc96922cd

Author: Karol Herbst <[email protected]>
Date:   Fri Sep 20 12:43:10 2019 +0200

clover/llvm: remove harmful std::move call

both clang and gcc warn with:
"moving a local object in a return statement prevents copy elision"

Signed-off-by: Karol Herbst <[email protected]>
Reviewed-by: Pierre Moreau <[email protected]>

---

 src/gallium/state_trackers/clover/llvm/invocation.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/state_trackers/clover/llvm/invocation.cpp 
b/src/gallium/state_trackers/clover/llvm/invocation.cpp
index d71ddf8b01b..bef334c2d63 100644
--- a/src/gallium/state_trackers/clover/llvm/invocation.cpp
+++ b/src/gallium/state_trackers/clover/llvm/invocation.cpp
@@ -376,7 +376,7 @@ namespace {
             throw build_error();
       }
 
-      return std::move(mod);
+      return mod;
    }
 }
 

_______________________________________________
mesa-commit mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to