Skip to content

Commit ca87480

Browse files
authored
[PWGJE] Fix: make doRhoAreaSub take const reference to avoid unnecesary copy (#11618)
1 parent 9197931 commit ca87480

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

PWGJE/Core/JetBkgSubUtils.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ std::tuple<double, double> JetBkgSubUtils::estimateRhoPerpCone(const std::vector
160160
return std::make_tuple(perpPtDensity, perpMdDensity);
161161
}
162162

163-
fastjet::PseudoJet JetBkgSubUtils::doRhoAreaSub(fastjet::PseudoJet& jet, double rhoParam, double rhoMParam)
163+
fastjet::PseudoJet JetBkgSubUtils::doRhoAreaSub(const fastjet::PseudoJet& jet, double rhoParam, double rhoMParam)
164164
{
165165

166166
fastjet::Subtractor sub = fastjet::Subtractor(rhoParam, rhoMParam);

PWGJE/Core/JetBkgSubUtils.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ class JetBkgSubUtils
7979
/// @param rhoParam the underlying evvent density vs pT (to be set)
8080
/// @param rhoParam the underlying evvent density vs jet mass (to be set)
8181
/// @return jet, background subtracted jet
82-
fastjet::PseudoJet doRhoAreaSub(fastjet::PseudoJet& jet, double rhoParam, double rhoMParam);
82+
fastjet::PseudoJet doRhoAreaSub(const fastjet::PseudoJet& jet, double rhoParam, double rhoMParam);
8383

8484
/// @brief method that subtracts the background from the input particles using the event-wise cosntituent subtractor
8585
/// @param inputParticles (all the tracks/clusters/particles in the event)

0 commit comments

Comments
 (0)