Skip to content
Snippets Groups Projects
Commit 10d46808 authored by Tadej Novak's avatar Tadej Novak
Browse files

Merge branch 'muonrdo' into 'main'

MuonRDO: fix uninitMemberVar cppcheck warning

See merge request atlas/athena!72866
parents c5fa7409 e379f4c7
No related branches found
No related tags found
No related merge requests found
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
*/
#ifndef MUONRDO_MM_RAWDATA_H
......@@ -26,25 +26,23 @@ class MM_RawData final{
private:
// not sure whether the offline identifier is needed
Identifier m_id;
Identifier m_id{};
/// channel Id
int m_channel;
int m_channel{0};
/// tdc counts or ns
int m_time;
int m_time{0};
/// adc counts or electrons
int m_charge;
int m_charge{0};
/// rel bcid
uint16_t m_relBcid;
uint16_t m_relBcid{0};
//indicator if the charge and time are in counts or physical units
bool m_timeAndChargeInCounts;
bool m_timeAndChargeInCounts{false};
public:
/** default constructor */
MM_RawData ( const Identifier& id ) : m_id(id), m_channel(0), m_time(0), m_charge(0), m_relBcid(0), m_timeAndChargeInCounts(0) {}
MM_RawData ( const Identifier& id ) : m_id(id) {}
MM_RawData ( const Identifier& id, const int channel,
const int time, const int charge, const uint16_t relBcid, bool timeAndChargeInCounts)
......
......@@ -23,11 +23,11 @@ public:
friend MsgStream& operator<<(MsgStream& stream, const NSW_PadTriggerSegment& rhs);
friend std::ostream& operator<<(std::ostream& stream, const NSW_PadTriggerSegment& rhs);
private:
uint8_t m_bandID;
uint8_t m_phiID;
uint8_t m_bandID{};
uint8_t m_phiID{};
// aka "coincidences", active layer count in each wedge ([0] = inner, [1] = outer)
std::array<uint8_t, 2> m_activeLayers;
std::array<uint8_t, 2> m_activeLayers{};
};
} // namespace Muon
#endif // MUONRDO_NSW_PADTRIGGERSEGMENT_H
\ No newline at end of file
#endif // MUONRDO_NSW_PADTRIGGERSEGMENT_H
/*
Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
*/
#ifndef MUONRDO_STGCRAWDATA_H
......@@ -19,17 +19,17 @@ class STGC_RawData final{
private:
// offline identifier
Identifier m_id;
Identifier m_id{};
// readout data
// keeping time in two variables: a float and an int. The float variable is kept for backward compatibility
float m_time;
unsigned int m_tdo; // time converted to TDC counts
unsigned int m_charge;
uint16_t m_bcTag;
float m_time{0};
unsigned int m_tdo{0}; // time converted to TDC counts
unsigned int m_charge{0};
uint16_t m_bcTag{0};
bool m_isDead;
bool m_timeAndChargeInCounts;
bool m_isDead{false};
bool m_timeAndChargeInCounts{false};
public:
......
/*
Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
*/
#include "MuonRDO/STGC_RawData.h"
......@@ -10,7 +10,7 @@
// P1 ------------------------
// Constructor for Hit
Muon::STGC_RawData::STGC_RawData(const Identifier id)
:m_id(id), m_time(0.0), m_tdo(0), m_charge(0), m_bcTag(0), m_isDead(false),m_timeAndChargeInCounts(false)
:m_id(id)
{
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment