Skip to content

Commit

Permalink
Fix warnings and remove CentOS7 from CI workflows (iLCSoft#71)
Browse files Browse the repository at this point in the history
* Backport of upstream PR to fix warnings etc.

* Remove centos7 from CI workflows

* Fix warnings that are now flagged
  • Loading branch information
tmadlener committed Nov 27, 2024
1 parent 67a301f commit 0ace7ba
Show file tree
Hide file tree
Showing 23 changed files with 1,001 additions and 964 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/key4hep.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
strategy:
matrix:
build_type: ["release", "nightly"]
image: ["alma9", "ubuntu22", "centos7"]
image: ["alma9", "ubuntu22"]
fail-fast: false

steps:
Expand Down
40 changes: 21 additions & 19 deletions source/Digitisers/include/DDPlanarDigiProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ class DDPlanarDigiProcessor : public Processor {


DDPlanarDigiProcessor() ;
DDPlanarDigiProcessor(const DDPlanarDigiProcessor&) = delete;
DDPlanarDigiProcessor& operator=(const DDPlanarDigiProcessor&) = delete;

/** Called at the begin of the job before anything is read.
* Use to initialize the processor, e.g. book histograms.
Expand Down Expand Up @@ -88,35 +90,35 @@ class DDPlanarDigiProcessor : public Processor {

protected:

std::string _inColName ;
std::string _inColName {};

std::string _outColName ;
std::string _outRelColName ;
std::string _outColName {};
std::string _outRelColName {};

std::string _subDetName ;
std::string _subDetName {};

int _nRun ;
int _nEvt ;
int _nRun {};
int _nEvt {};

FloatVec _resU ;
FloatVec _resV ;
FloatVec _resT ;
FloatVec _resU {};
FloatVec _resV {};
FloatVec _resT {};

bool _isStrip;
bool _isStrip{};

gsl_rng* _rng ;
gsl_rng* _rng {nullptr};

const dd4hep::rec::SurfaceMap* _map ;
const dd4hep::rec::SurfaceMap* _map {nullptr};

bool _forceHitsOntoSurface ;
double _minEnergy ;
bool _forceHitsOntoSurface {};
double _minEnergy {};

bool _useTimeWindow ;
bool _correctTimesForPropagation ;
FloatVec _timeWindow_min ;
FloatVec _timeWindow_max ;
bool _useTimeWindow {};
bool _correctTimesForPropagation {};
FloatVec _timeWindow_min {};
FloatVec _timeWindow_max {};

std::vector<TH1F*> _h ;
std::vector<TH1F*> _h {};

} ;

Expand Down
37 changes: 20 additions & 17 deletions source/Digitisers/include/DDSpacePointBuilder.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@ class DDSpacePointBuilder : public Processor {


DDSpacePointBuilder() ;

DDSpacePointBuilder(const DDSpacePointBuilder&) = delete;
DDSpacePointBuilder& operator=(const DDSpacePointBuilder&) = delete;

/** Called at the begin of the job before anything is read.
* Use to initialize the processor, e.g. book histograms.
Expand Down Expand Up @@ -102,19 +105,19 @@ class DDSpacePointBuilder : public Processor {

/** Input collection name.
*/
std::string _TrackerHitCollection;
std::string _TrackerHitCollection{};

/** Input relation collection name.
*/
std::string _TrackerHitSimHitRelCollection;
std::string _TrackerHitSimHitRelCollection{};

/** Output collection name.
*/
std::string _SpacePointsCollection;
std::string _SpacePointsCollection{};

/** Output relations collection name.
*/
std::string _relColName;
std::string _relColName{};

/** Calculates the 2 dimensional crossing point of two lines.
* Each line is specified by a point (x,y) and a direction vector (ex,ey).
Expand Down Expand Up @@ -196,26 +199,26 @@ class DDSpacePointBuilder : public Processor {
std::string getCellID0Info( int cellID0 );


int _nRun ;
int _nEvt ;
int _nRun {};
int _nEvt {};

unsigned _nOutOfBoundary;
unsigned _nStripsTooParallel;
unsigned _nPlanesNotParallel;
unsigned _nOutOfBoundary{};
unsigned _nStripsTooParallel{};
unsigned _nPlanesNotParallel{};

float _nominal_vertex_x;
float _nominal_vertex_y;
float _nominal_vertex_z;
float _nominal_vertex_x{};
float _nominal_vertex_y{};
float _nominal_vertex_z{};

CLHEP::Hep3Vector _nominal_vertex;
CLHEP::Hep3Vector _nominal_vertex{};

float _striplength_tolerance;
float _striplength_tolerance{};

double _striplength ;
std::string _subDetName ;
double _striplength {};
std::string _subDetName {};

//dd4hep::Detector& lcdd;
const dd4hep::rec::SurfaceMap* surfMap ;
const dd4hep::rec::SurfaceMap* surfMap {nullptr};

} ;

Expand Down
3 changes: 3 additions & 0 deletions source/Digitisers/include/DDTPCDigiProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,9 @@ class DDTPCDigiProcessor : public marlin::Processor {

DDTPCDigiProcessor() ;

DDTPCDigiProcessor(const DDTPCDigiProcessor&) = delete;
DDTPCDigiProcessor& operator=(const DDTPCDigiProcessor&) = delete;

~DDTPCDigiProcessor() ;

/** Called at the begin of the job before anything is read.
Expand Down
4 changes: 2 additions & 2 deletions source/Digitisers/src/FixedPadSizeDiskLayout.cc
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ double FixedPadSizeDiskLayout::getPadWidth(int padIndex) const {
return _padWidth / _rows.at( rowNum ).RCenter ;

}
catch(std::out_of_range){
catch(std::out_of_range&){
return 0. ;
}
}
Expand All @@ -162,7 +162,7 @@ double FixedPadSizeDiskLayout::getPadPitch(int padIndex) const {
return _rows.at( rowNum ).PhiPad;

}
catch(std::out_of_range){
catch(std::out_of_range&){
return 0. ;
}
}
Expand Down
3 changes: 2 additions & 1 deletion source/Digitisers/src/TPCModularEndplate.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ class TPCModularEndplate {

/// no default c'tor
TPCModularEndplate() = delete ;

TPCModularEndplate(const TPCModularEndplate&) = delete;
TPCModularEndplate& operator=(const TPCModularEndplate&) = delete;

/// intitialize for the gice TPC data
TPCModularEndplate( const dd4hep::rec::FixedPadSizeTPCData* tpc ) ;
Expand Down
16 changes: 8 additions & 8 deletions source/Refitting/include/ClonesAndSplitTracksFinder.h
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ class ClonesAndSplitTracksFinder : public marlin::Processor {

lcio::LCCollection* GetCollection(lcio::LCEvent* evt, std::string colName);

std::string _input_track_col_name;
std::string _output_track_col_name;
std::string _input_track_col_name{};
std::string _output_track_col_name{};

MarlinTrk::IMarlinTrkSystem* _trksystem = nullptr;

Expand All @@ -95,12 +95,12 @@ class ClonesAndSplitTracksFinder : public marlin::Processor {
bool _mergeSplitTracks = false;

// Track fit parameters
double _initialTrackError_d0;
double _initialTrackError_phi0;
double _initialTrackError_omega;
double _initialTrackError_z0;
double _initialTrackError_tanL;
double _maxChi2perHit;
double _initialTrackError_d0{};
double _initialTrackError_phi0{};
double _initialTrackError_omega{};
double _initialTrackError_z0{};
double _initialTrackError_tanL{};
double _maxChi2perHit{};

std::shared_ptr<UTIL::BitField64> _encoder{};
};
Expand Down
Loading

0 comments on commit 0ace7ba

Please sign in to comment.