Skip to content

Commit 68b47fc

Browse files
authored
Merge pull request #49495 from smuzaffar/fastsim-llvm21-clang-tidy
[FASTSIM] [LLVM21] Apply clang-tidy changes
2 parents 7b278ea + dd10790 commit 68b47fc

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

FastSimulation/Muons/plugins/FastTSGFromL2Muon.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ void FastTSGFromL2Muon::produce(edm::Event& ev, const edm::EventSetup& es) {
7272
std::set<unsigned> tkIds;
7373
tkSeeds.reserve(seed_size);
7474
for (unsigned iseed = 0; iseed < seedCollections; ++iseed) {
75-
edm::Handle<edm::View<TrajectorySeed> > aSeedCollection = theSeeds[iseed];
75+
const edm::Handle<edm::View<TrajectorySeed> >& aSeedCollection = theSeeds[iseed];
7676
unsigned nSeeds = aSeedCollection->size();
7777
for (unsigned seednr = 0; seednr < nSeeds; ++seednr) {
7878
// The seed

FastSimulation/ParticleDecay/plugins/TestPythiaDecays.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,7 @@ void TestPythiaDecays::analyze(const edm::Event& iEvent, const edm::EventSetup&
325325

326326
// fill br hist
327327
std::vector<int> prod;
328+
prod.reserve(childIndices.size());
328329
for (size_t d = 0; d < childIndices.size(); ++d) {
329330
prod.push_back(abs(simtracks->at(childIndices[d]).type()));
330331
}

FastSimulation/Utilities/src/Looses.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ Looses::~Looses() { summary(); }
1919
void Looses::count(const std::string& name, unsigned cut) {
2020
if (theLosses.find(name) == theLosses.end()) {
2121
std::vector<unsigned> myCounts;
22+
myCounts.reserve(20);
2223
for (unsigned i = 0; i < 20; ++i)
2324
myCounts.push_back(0);
2425
theLosses[name] = myCounts;

0 commit comments

Comments
 (0)