Skip to content

Commit

Permalink
Propagate upstream changes: Geant4Hits header removed in dd4hep
Browse files Browse the repository at this point in the history
The classes defined in this header are not used in any case, the include can just be replaced with another one that provides dd4hep::Segmentation. Includes some fixes for compiler warnings
  • Loading branch information
vvolkl committed Jul 17, 2022
1 parent e4f439c commit 0eb6d82
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 8 deletions.
3 changes: 2 additions & 1 deletion SimG4Components/src/InspectHitsCollectionsTool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
#include "G4Event.hh"

// DD4hep
#include "DDG4/Geant4Hits.h"
#include "DD4hep/Detector.h"
#include "DD4hep/Segmentations.h"

DECLARE_COMPONENT(InspectHitsCollectionsTool)

Expand Down
2 changes: 1 addition & 1 deletion SimG4Components/src/SimG4GeantinoDeposits.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class SimG4GeantinoDeposits: public AlgTool, virtual public ISimG4PhysicsList {
/** Get the physics list.
* @return pointer to G4VModularPhysicsList (ownership is transferred to the caller)
*/
virtual G4VModularPhysicsList* physicsList();
virtual G4VModularPhysicsList* physicsList() override final;

};

Expand Down
3 changes: 2 additions & 1 deletion SimG4Components/src/SimG4SaveCalHits.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
#include "edm4hep/SimCalorimeterHitCollection.h"

// DD4hep
#include "DDG4/Geant4Hits.h"
#include "DD4hep/Detector.h"
#include "DD4hep/Segmentations.h"


DECLARE_COMPONENT(SimG4SaveCalHits)
Expand Down
2 changes: 1 addition & 1 deletion SimG4Components/src/SimG4SaveSmearedParticles.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include "edm4hep/MCRecoParticleAssociationCollection.h"

// DD4hep
#include "DDG4/Geant4Hits.h"
#include "DD4hep/Segmentations.h"

DECLARE_COMPONENT(SimG4SaveSmearedParticles)

Expand Down
6 changes: 3 additions & 3 deletions SimG4Components/src/SimG4SmearGenParticles.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include "edm4hep/MCParticleCollection.h"

// DD4hep
#include "DDG4/Geant4Hits.h"
#include "DD4hep/Segmentations.h"

DECLARE_COMPONENT(SimG4SmearGenParticles)

Expand All @@ -26,10 +26,10 @@ StatusCode SimG4SmearGenParticles::initialize() {
StatusCode sc = GaudiAlgorithm::initialize();
// Use smearing tool
if (!m_smearTool.retrieve()) {
info() << "Generated particels will not be smeared!!!" << endmsg;
info() << "Generated particles will not be smeared!!!" << endmsg;
return StatusCode::SUCCESS;
}
return StatusCode::SUCCESS;
return sc;
}

StatusCode SimG4SmearGenParticles::execute() {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#ifndef SIMG4INTERFACE_ISIMG4MAGNETICFIELDTOOL_H
#define SIMG4INTERFACE_ISIM4MAGNETICFIELDTOOL_H
#define SIMG4INTERFACE_ISIMG4MAGNETICFIELDTOOL_H

// from Gaudi
#include "GaudiKernel/IAlgTool.h"
Expand Down

0 comments on commit 0eb6d82

Please sign in to comment.