Skip to content

egammaConditions: string by const ref&

std::string Pass by const ref rahter than value , mentioning @wlampl for his info.

examples

EMDatabaseID.cxx:36:40: warning: the parameter 'Object' is copied for each invocation but only used as a const reference; consider making it a const reference [performance-unnecessary-value-param]
EMDatabaseID::EMDatabaseID(std::string Object, std::string Container, std::string Type, std::string Channel, std::string Author, std::string RecoSWV, std::string Tag, long start, long end)
                                       ^
                           const      &
EMDatabaseID.cxx:128:59: warning: passing result of std::move() as a const reference argument; no move will actually happen [performance-move-const-arg]
  set(std::move(Object), "", std::move(Type), "", "", "", std::move(Tag), "");

Merge request reports