Skip to content

Commit 98b577a

Browse files
committed
[PWGJE] Fix O2 linter errors
1 parent f63c614 commit 98b577a

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

PWGJE/Tasks/jetDsSpectrumAndSubstructure.cxx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -289,9 +289,13 @@ struct JetDsSpecSubs {
289289

290290
// --- output table ---
291291
auto scores = dsCandidate.mlScores();
292-
const float s0 = (scores.size() > 0) ? scores[0] : -999.f;
293-
const float s1 = (scores.size() > 1) ? scores[1] : -999.f;
294-
const float s2 = (scores.size() > 2) ? scores[2] : -999.f;
292+
constexpr int kScore0 = 0;
293+
constexpr int kScore1 = 1;
294+
constexpr int kScore2 = 2;
295+
296+
const float s0 = (scores.size() > kScore0) ? scores[kScore0] : -999.f;
297+
const float s1 = (scores.size() > kScore1) ? scores[kScore1] : -999.f;
298+
const float s2 = (scores.size() > kScore2) ? scores[kScore2] : -999.f;
295299

296300
distJetTable(static_cast<float>(axisDistance),
297301
jet.pt(), jet.eta(), jet.phi(),

0 commit comments

Comments
 (0)