Skip to content

Commit 6d0e2b7

Browse files
authored
Remove redundant std::move noted by gcc 9.2 (-Wredundant-move) (microsoft#1370)
1 parent 927afad commit 6d0e2b7

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Release/src/json/json_parsing.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1040,7 +1040,7 @@ std::unique_ptr<web::json::details::_Value> JSON_Parser<CharType>::_ParseArray(
10401040
case JSON_Parser<CharType>::Token::TKN_CloseBracket:
10411041
GetNextToken(tkn);
10421042
if (tkn.m_error) return utility::details::make_unique<web::json::details::_Null>();
1043-
return std::move(result);
1043+
return result;
10441044
default:
10451045
SetErrorCode(tkn, json_error::malformed_array_literal);
10461046
return utility::details::make_unique<web::json::details::_Null>();
@@ -1074,7 +1074,7 @@ std::unique_ptr<web::json::details::_Value> JSON_Parser<CharType>::_ParseValue(
10741074
tkn.has_unescape_symbol);
10751075
GetNextToken(tkn);
10761076
if (tkn.m_error) return utility::details::make_unique<web::json::details::_Null>();
1077-
return std::move(value);
1077+
return value;
10781078
}
10791079
case JSON_Parser<CharType>::Token::TKN_IntegerLiteral:
10801080
{
@@ -1086,21 +1086,21 @@ std::unique_ptr<web::json::details::_Value> JSON_Parser<CharType>::_ParseValue(
10861086

10871087
GetNextToken(tkn);
10881088
if (tkn.m_error) return utility::details::make_unique<web::json::details::_Null>();
1089-
return std::move(value);
1089+
return value;
10901090
}
10911091
case JSON_Parser<CharType>::Token::TKN_NumberLiteral:
10921092
{
10931093
auto value = utility::details::make_unique<web::json::details::_Number>(tkn.double_val);
10941094
GetNextToken(tkn);
10951095
if (tkn.m_error) return utility::details::make_unique<web::json::details::_Null>();
1096-
return std::move(value);
1096+
return value;
10971097
}
10981098
case JSON_Parser<CharType>::Token::TKN_BooleanLiteral:
10991099
{
11001100
auto value = utility::details::make_unique<web::json::details::_Boolean>(tkn.boolean_val);
11011101
GetNextToken(tkn);
11021102
if (tkn.m_error) return utility::details::make_unique<web::json::details::_Null>();
1103-
return std::move(value);
1103+
return value;
11041104
}
11051105
case JSON_Parser<CharType>::Token::TKN_NullLiteral:
11061106
{

0 commit comments

Comments
 (0)