diff --git a/LHCbG4Tests/G4MScInThinLayerTest/CMakeLists.txt b/LHCbG4Tests/G4MScInThinLayerTest/CMakeLists.txt index 9ddb1b839a87bba17f0d7d56e91a6e2434615776..0680977bf42063e3eea2140aecd1a50ee5e08d3c 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/CMakeLists.txt +++ b/LHCbG4Tests/G4MScInThinLayerTest/CMakeLists.txt @@ -6,7 +6,8 @@ gaudi_depends_on_subdirs(LHCbG4PhysLists) find_package(CLHEP REQUIRED) find_package(ROOT COMPONENTS Hist Gpad RIO) -include_directories(${CMAKE_INSTALL_PREFIX}/include) +include_directories(SYSTEM ${CMAKE_INSTALL_PREFIX}/include ${CLHEP_INCLUDE_DIRS} ${ROOT_INCLUDE_DIRS}) +#include_directories(${CMAKE_INSTALL_PREFIX}/include) link_directories(${CMAKE_INSTALL_PREFIX}/lib) set(Geant4_LIBRARIES @@ -26,7 +27,4 @@ gaudi_add_executable(G4MScInThinLayerTest add_dependencies(G4MScInThinLayerTest Geant4) -# Dirty fix to disable the pesky warning -set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-suggest-override") - gaudi_install_scripts() diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/ActionInitialization.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/ActionInitialization.hh index 0a471e883858d3e3a468835794fa8b1561c4fc7b..9522b5d495034ccc4baca1661cd6809a752d0053 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/ActionInitialization.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/ActionInitialization.hh @@ -49,10 +49,10 @@ class ActionInitialization : public G4VUserActionInitialization ActionInitialization(DetectorConstruction*, RMSPlotter*); virtual ~ActionInitialization(); - virtual void BuildForMaster() const; - virtual void Build() const; + void BuildForMaster() const override; + void Build() const override; - virtual G4VSteppingVerbose* InitializeSteppingVerbose() const; + G4VSteppingVerbose* InitializeSteppingVerbose() const override; private: DetectorConstruction* fDetector; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorConstruction.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorConstruction.hh index 3d07d9e22c7ae142215a36279cd1991232641bb6..687df6df0676b7e5928dd6eb20f8a6e59b63c975 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorConstruction.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorConstruction.hh @@ -70,8 +70,8 @@ class DetectorConstruction : public G4VUserDetectorConstruction void SetMagField(G4double); - virtual G4VPhysicalVolume* Construct(); - virtual void ConstructSDandField(); + G4VPhysicalVolume* Construct() override; + void ConstructSDandField() override; public: diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorMessenger.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorMessenger.hh index 7cde110960d3e9184c5b4c38072eb9f29291613c..8c3bf7d0878475e32179142c6b47d7bf1d306747 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorMessenger.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/DetectorMessenger.hh @@ -52,7 +52,7 @@ class DetectorMessenger: public G4UImessenger DetectorMessenger(DetectorConstruction* ); ~DetectorMessenger(); - virtual void SetNewValue(G4UIcommand*, G4String); + void SetNewValue(G4UIcommand*, G4String) override; private: DetectorConstruction* fDetector; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/EventAction.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/EventAction.hh index c2b606842337f8efce69dce66d770ea08dc16b88..1e5b423d7644cc000286ab22d331e4112b92d3cc 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/EventAction.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/EventAction.hh @@ -46,8 +46,8 @@ class EventAction : public G4UserEventAction ~EventAction(); public: - virtual void BeginOfEventAction(const G4Event*); - virtual void EndOfEventAction(const G4Event*); + void BeginOfEventAction(const G4Event*) override; + void EndOfEventAction(const G4Event*) override; void AddEnergy (G4double edep) {fEnergyDeposit += edep;}; void AddTrakLenCharg(G4double length) {fTrakLenCharged += length;}; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandard.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandard.hh index b49de04b5c8faceffa34fff770f9a8a892e1fae9..83b4b6efb0b0240ae9e50ca6a48c9d2fd6897e79 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandard.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandard.hh @@ -47,12 +47,12 @@ public: public: // This method is dummy for physics - virtual void ConstructParticle() {}; + void ConstructParticle() override {}; // This method will be invoked in the Construct() method. // each physics process will be instantiated and // registered to the process manager of each particle type - virtual void ConstructProcess(); + void ConstructProcess() override; }; //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandardSSM.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandardSSM.hh index c277c880bf1184a95f53d0b72e735a4c7abaebdb..3e7e87e3dd97f7ddd1fc0af98153cf1719b7cca5 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandardSSM.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysListEmStandardSSM.hh @@ -47,12 +47,12 @@ public: public: // This method is dummy for physics - virtual void ConstructParticle() {}; + void ConstructParticle() override {}; // This method will be invoked in the Construct() method. // each physics process will be instantiated and // registered to the process manager of each particle type - virtual void ConstructProcess(); + void ConstructProcess() override; }; //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsList.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsList.hh index 3a8ee18eb1af54aad1294ed410fd3b2c40e98ca3..e6e74ca5946cb85a6685eb628524fad35d60281b 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsList.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsList.hh @@ -48,11 +48,11 @@ public: PhysicsList(); ~PhysicsList(); - virtual void ConstructParticle(); + void ConstructParticle() override; void AddPhysicsList(const G4String& name); - virtual void ConstructProcess(); + void ConstructProcess() override; void AddDecay(); void AddStepMax(); diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsListMessenger.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsListMessenger.hh index 55d1d259cd4b01efb15616eabd865341fc24cf20..17e403827f15b69f73a2152f438ab399123ff80a 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsListMessenger.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/PhysicsListMessenger.hh @@ -51,7 +51,7 @@ public: PhysicsListMessenger(PhysicsList* ); ~PhysicsListMessenger(); - virtual void SetNewValue(G4UIcommand*, G4String); + void SetNewValue(G4UIcommand*, G4String) override; private: diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorAction.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorAction.hh index 46fab9a5f2fdc69d0711380ad628479d32979f15..d36282c315d59b5ef2230675aceaf209424a2c4b 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorAction.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorAction.hh @@ -53,7 +53,7 @@ class PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction public: void SetDefaultKinematic(); void SetRndmBeam(G4double val) {fRndmBeam = val;}; - virtual void GeneratePrimaries(G4Event*); + void GeneratePrimaries(G4Event*) override; G4ParticleGun* GetParticleGun() {return fParticleGun;}; private: diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorMessenger.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorMessenger.hh index d3072a4e44482563a41dbc9a336e366298bb16a8..a04dbad2b22ad476158720f97345eaba39cecbd5 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorMessenger.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/PrimaryGeneratorMessenger.hh @@ -50,7 +50,7 @@ class PrimaryGeneratorMessenger: public G4UImessenger PrimaryGeneratorMessenger(PrimaryGeneratorAction*); ~PrimaryGeneratorMessenger(); - virtual void SetNewValue(G4UIcommand*, G4String); + void SetNewValue(G4UIcommand*, G4String) override; private: PrimaryGeneratorAction* fAction; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/Run.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/Run.hh index ae2e3ce2874d7949fe95d4119565db824985098f..3ced63de8a5df49a7e1fe9f14674940f44a22682 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/Run.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/Run.hh @@ -97,7 +97,7 @@ class Run : public G4Run G4double ComputeMscHighland(); - virtual void Merge(const G4Run*); + void Merge(const G4Run*) override; void EndOfRun(RMSPlotter* rmsplotter); diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/RunAction.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/RunAction.hh index ebd6f14ec59dde30f4cf846e60d4c0d19142a78f..616ed2ef393ad27366a2aa11a36b2bb1a754a69b 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/RunAction.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/RunAction.hh @@ -57,9 +57,9 @@ public: RunAction(DetectorConstruction* det, PrimaryGeneratorAction* prim = 0, RMSPlotter* rmsplotter = 0); ~RunAction(); - virtual G4Run* GenerateRun(); - virtual void BeginOfRunAction(const G4Run*); - virtual void EndOfRunAction(const G4Run*); + G4Run* GenerateRun() override; + void BeginOfRunAction(const G4Run*) override; + void EndOfRunAction(const G4Run*) override; private: DetectorConstruction* fDetector; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/StackingAction.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/StackingAction.hh index 835ddac313c27164307ad3a98253b50397a5f5d6..3a13b6a9409902dfaeb5a4fac393da545e5bbb92 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/StackingAction.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/StackingAction.hh @@ -50,7 +50,7 @@ class StackingAction : public G4UserStackingAction void SetKillStatus(G4int value) { fKillSecondary = value;}; - virtual G4ClassificationOfNewTrack ClassifyNewTrack(const G4Track*); + G4ClassificationOfNewTrack ClassifyNewTrack(const G4Track*) override; private: EventAction* fEventAction; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/StackingMessenger.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/StackingMessenger.hh index 7a827b1df9d7fafa228b331fcbfcae3040982d41..26c00c450418f03dbf2a496a839961d5ef596e5d 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/StackingMessenger.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/StackingMessenger.hh @@ -49,7 +49,7 @@ class StackingMessenger: public G4UImessenger StackingMessenger(StackingAction*); ~StackingMessenger(); - virtual void SetNewValue(G4UIcommand*, G4String); + void SetNewValue(G4UIcommand*, G4String) override; private: StackingAction* fStackAction; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/StepMax.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/StepMax.hh index 87698d2d815cc28398c00a57320065b68d349cbf..df2b3fd1aa1a7b9617a357a3911e9fd799235565 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/StepMax.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/StepMax.hh @@ -50,17 +50,17 @@ class StepMax : public G4VDiscreteProcess StepMax(const G4String& processName ="UserStepMax"); ~StepMax(); - virtual G4bool IsApplicable(const G4ParticleDefinition&); + G4bool IsApplicable(const G4ParticleDefinition&) override; void SetMaxStep(G4double); G4double GetMaxStep() {return fMaxChargedStep;}; - virtual G4double PostStepGetPhysicalInteractionLength(const G4Track& track, - G4double previousStepSize, - G4ForceCondition* condition); + G4double PostStepGetPhysicalInteractionLength(const G4Track& track, + G4double previousStepSize, + G4ForceCondition* condition) override; - virtual G4VParticleChange* PostStepDoIt(const G4Track&, const G4Step&); + G4VParticleChange* PostStepDoIt(const G4Track&, const G4Step&) override; - virtual G4double GetMeanFreePath(const G4Track&,G4double,G4ForceCondition*) + G4double GetMeanFreePath(const G4Track&,G4double,G4ForceCondition*) override {return 0.;}; // it is not needed here ! private: diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/StepMaxMessenger.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/StepMaxMessenger.hh index 9a1bcfc1a3babedff3132e20f425cbd57de82cc3..160cf833de36c18e16f3b91608c31332445fd567 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/StepMaxMessenger.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/StepMaxMessenger.hh @@ -48,7 +48,7 @@ class StepMaxMessenger: public G4UImessenger StepMaxMessenger(StepMax*); ~StepMaxMessenger(); - virtual void SetNewValue(G4UIcommand*, G4String); + void SetNewValue(G4UIcommand*, G4String) override; private: StepMax* fStepMax; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingAction.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingAction.hh index 079188923f9ec704af764bbdcaf4b14685fb015e..d73db216095282945430b942405ccacb2b0cf463 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingAction.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingAction.hh @@ -49,7 +49,7 @@ class SteppingAction : public G4UserSteppingAction SteppingAction(DetectorConstruction*,EventAction*); ~SteppingAction(); - virtual void UserSteppingAction(const G4Step*); + void UserSteppingAction(const G4Step*) override; private: DetectorConstruction* fDetector; diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingVerbose.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingVerbose.hh index 3ec81f8314c9eab5173479a54bd67f073154baa8..7af703994f99b0b19c0d33b639a65ba3233ff7c7 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingVerbose.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/SteppingVerbose.hh @@ -46,8 +46,8 @@ public: SteppingVerbose(); ~SteppingVerbose(); - virtual void TrackingStarted(); - virtual void StepInfo(); + void TrackingStarted() override; + void StepInfo() override; }; //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... diff --git a/LHCbG4Tests/G4MScInThinLayerTest/include/TrackingAction.hh b/LHCbG4Tests/G4MScInThinLayerTest/include/TrackingAction.hh index 89564b42bdc634dfc91b0c2fe0da77936858a4da..f7692da4e65dc3639f6c761d677c97ef3811fad7 100644 --- a/LHCbG4Tests/G4MScInThinLayerTest/include/TrackingAction.hh +++ b/LHCbG4Tests/G4MScInThinLayerTest/include/TrackingAction.hh @@ -50,8 +50,8 @@ class TrackingAction : public G4UserTrackingAction { TrackingAction(DetectorConstruction*, EventAction*, RMSPlotter*); ~TrackingAction() {}; - virtual void PreUserTrackingAction(const G4Track*); - virtual void PostUserTrackingAction(const G4Track*); + void PreUserTrackingAction(const G4Track*) override; + void PostUserTrackingAction(const G4Track*) override; private: DetectorConstruction* fDetector;