Fix clang warnings about copy elision
When building with clang, I get:
/home/emaisin/src/binutils-gdb/gdb/osdata.c:107:9: error: moving a temporary object prevents copy elision [-Werror,-Wpessimizing-move]
std::move (std::string (body_text)));
^
/home/emaisin/src/binutils-gdb/gdb/osdata.c:107:9: note: remove std::move call here
std::move (std::string (body_text)));
^~~~~~~~~~~ ~
/home/emaisin/src/binutils-gdb/gdb/osdata.c:181:10: error: moving a local object in a return statement prevents copy elision [-Werror,-Wpessimizing-move]
return std::move (osdata);
^
/home/emaisin/src/binutils-gdb/gdb/osdata.c:181:10: note: remove std::move call here
return std::move (osdata);
^~~~~~~~~~~ ~
Indeed, those two std::move are unnecessary.
gdb/ChangeLog:
* osdata.c (osdata_end_column, get_osdata): Remove std::move.