Skip to content

Commit 9612de8

Browse files
committed
Fix compiler warnings by not std::move()ing where redundant
1 parent 78631fa commit 9612de8

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

lib/base/object-packer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,5 +242,5 @@ String icinga::PackObject(const Value& value)
242242
std::string builder;
243243
PackAny(value, builder);
244244

245-
return std::move(builder);
245+
return builder;
246246
}

lib/config/config_parser.yy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ std::unique_ptr<Expression> ConfigCompiler::Compile()
280280

281281
std::unique_ptr<DictExpression> expr{new DictExpression(std::move(dlist))};
282282
expr->MakeInline();
283-
return std::move(expr);
283+
return expr;
284284
}
285285

286286
#define scanner (context->GetScanner())

lib/config/configcompiler.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ std::unique_ptr<Expression> ConfigCompiler::HandleInclude(const String& relative
146146

147147
std::unique_ptr<DictExpression> expr{new DictExpression(std::move(expressions))};
148148
expr->MakeInline();
149-
return std::move(expr);
149+
return expr;
150150
}
151151

152152
/**
@@ -174,7 +174,7 @@ std::unique_ptr<Expression> ConfigCompiler::HandleIncludeRecursive(const String&
174174

175175
std::unique_ptr<DictExpression> dict{new DictExpression(std::move(expressions))};
176176
dict->MakeInline();
177-
return std::move(dict);
177+
return dict;
178178
}
179179

180180
void ConfigCompiler::HandleIncludeZone(const String& relativeBase, const String& tag, const String& path, const String& pattern, const String& package, std::vector<std::unique_ptr<Expression> >& expressions)

0 commit comments

Comments
 (0)