mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2026-07-12 02:01:36 +00:00
perf: avoid copies in range-based for loops
- take loop variables by const reference where the body does not modify them - clang-tidy performance-for-range-copy https://clang.llvm.org/extra/clang-tidy/checks/performance/for-range-copy.html
This commit is contained in:
committed by
Dennis Klein
parent
7a44c5e19e
commit
0feda158b4
@@ -79,7 +79,7 @@ Properties SuboptParser(const vector<string>& channelConfig, const string& devic
|
||||
|
||||
ptree channelsArray;
|
||||
|
||||
for (auto token : channelConfig) {
|
||||
for (const auto& token : channelConfig) {
|
||||
string channelName;
|
||||
ptree channelProperties;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user