Skip to content

Commit f4f65e2

Browse files
authored
[PWGEM] Clean up of clang-tidy errors and warnings from #17288 (#17310)
1 parent 6b35bd4 commit f4f65e2

2 files changed

Lines changed: 8 additions & 4 deletions

File tree

PWGEM/PhotonMeson/TableProducer/photonconversionbuilder.cxx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
#include <Framework/HistogramSpec.h>
5353
#include <Framework/InitContext.h>
5454
#include <Framework/runDataProcessing.h>
55+
#include <ReconstructionDataFormats/HelixHelper.h>
5556
#include <ReconstructionDataFormats/PID.h>
5657

5758
#include <Math/Vector4D.h> // IWYU pragma: keep (do not replace with Math/Vector4Dfwd.h)
@@ -62,6 +63,8 @@
6263
#include <KFPVertex.h>
6364
#include <KFParticle.h>
6465

66+
#include <GPUROOTCartesianFwd.h>
67+
6568
#include <algorithm>
6669
#include <array>
6770
#include <cmath>
@@ -681,9 +684,8 @@ struct PhotonConversionBuilder {
681684
phiv = o2::aod::pwgem::dilepton::utils::pairutil::getPhivPair(kfp_track_posProp.GetPx(), kfp_track_posProp.GetPy(), kfp_track_posProp.GetPz(), kfp_track_eleProp.GetPx(), kfp_track_eleProp.GetPy(), kfp_track_eleProp.GetPz(), pos.sign(), ele.sign(), d_bz);
682685
psipair = o2::aod::pwgem::dilepton::utils::pairutil::getPsiPair(kfp_track_posProp.GetPx(), kfp_track_posProp.GetPy(), kfp_track_posProp.GetPz(), kfp_track_eleProp.GetPx(), kfp_track_eleProp.GetPy(), kfp_track_eleProp.GetPz());
683686
break;
684-
} else {
685-
LOG(debug) << "Propagation to offset" << offsetR << " cm failed for " << (pPropagatedSuccess ? "negative" : "positive") << " track. Trying smaller offset.";
686687
}
688+
LOG(debug) << "Propagation to offset" << offsetR << " cm failed for " << (pPropagatedSuccess ? "negative" : "positive") << " track. Trying smaller offset.";
687689
}
688690
if (modeTrackPropagation == TrackPropMode::kBoth) {
689691
registry.fill(HIST("V0/hPhivPropagationCompare"), phiv, phivFast);

PWGEM/PhotonMeson/Utils/PCMUtilities.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@
3030
#include <Math/Vector2D.h> // IWYU pragma: keep (do not replace with Math/Vector2Dfwd.h)
3131
#include <Math/Vector2Dfwd.h>
3232

33+
#include <GPUROOTCartesianFwd.h>
34+
3335
#include <array>
3436
#include <cmath>
3537

@@ -113,7 +115,7 @@ template <typename TrackPrecision = float>
113115
std::array<float, 2> CalculateDCAFast(const o2::track::TrackParametrizationWithError<TrackPrecision>& trk, const o2::math_utils::Point3D<float>& vtx, const float magField)
114116
{
115117

116-
std::array<float, 2> dca;
118+
std::array<float, 2> dca{};
117119

118120
// obtain circle from track in x-y plane
119121
const o2::track::TrackAuxPar helixPos(trk, magField);
@@ -175,7 +177,7 @@ inline std::array<float, 3> getPropMomentumFromTrackHelix(const float s, const T
175177
const auto phi = RecoDecay::constrainAngle<float>(track.phi() + dphi + addPhi);
176178

177179
// Calculate px,y,z at the new propagated vertex
178-
std::array<float, 3> trackP;
180+
std::array<float, 3> trackP{};
179181
trackP[0] = std::cos(phi) * track.pt();
180182
trackP[1] = std::sin(phi) * track.pt();
181183
trackP[2] = track.tgl() * track.pt();

0 commit comments

Comments
 (0)