From 529af5ed210cc287ae80b05b16339c9df6c67ae7 Mon Sep 17 00:00:00 2001 From: Giulio Eulisse Date: Fri, 9 May 2014 12:36:54 +0200 Subject: [PATCH] More clang fixes. --- .../ParticleFlowCandidate/interface/PFCandidate.h | 2 +- PhysicsTools/JetMCUtils/interface/combination.h | 2 -- .../interface/L3MuonTrajectoryBuilder.h | 1 + .../PFTracking/interface/PFElecTkProducer.h | 1 - RecoTracker/TkMSParametrization/interface/MSLayer.h | 2 +- .../ConfigurableTertiaryTracksVertexFinder.h | 1 + .../interface/TertiaryTracksVertexFinder.h | 1 + .../src/GetLineCovMatrix.cc | 6 +++--- .../EcalElectronicsEmulation/bin/GenABIO.cc | 13 ------------- .../bin/TtSemiLRJetComb_PurityLoop.cpp | 1 - .../TopSkimming/src/TtDecayChannelSelector.cc | 3 --- .../src/AnalyticalImpactPointExtrapolator.cc | 2 +- Validation/RecoTau/plugins/DQMHistPlotter.cc | 4 ---- 13 files changed, 9 insertions(+), 30 deletions(-) diff --git a/DataFormats/ParticleFlowCandidate/interface/PFCandidate.h b/DataFormats/ParticleFlowCandidate/interface/PFCandidate.h index 76727a946bbd8..ea05d90d0e2ab 100755 --- a/DataFormats/ParticleFlowCandidate/interface/PFCandidate.h +++ b/DataFormats/ParticleFlowCandidate/interface/PFCandidate.h @@ -119,7 +119,7 @@ namespace reco { /* return CandidateBaseRef(sourceRef_); */ /* } */ - //using reco::Candidate::setSourceCandidatePtr; + using reco::Candidate::setSourceCandidatePtr; void setSourceCandidatePtr(const PFCandidatePtr& ptr) { sourcePtr_ = ptr; } size_t numberOfSourceCandidatePtrs() const { diff --git a/PhysicsTools/JetMCUtils/interface/combination.h b/PhysicsTools/JetMCUtils/interface/combination.h index 630f6a22e4d8b..df5541218ed37 100644 --- a/PhysicsTools/JetMCUtils/interface/combination.h +++ b/PhysicsTools/JetMCUtils/interface/combination.h @@ -150,7 +150,6 @@ inline bool prev_combination(BidIt n_begin, BidIt n_end, BidIt r_begin, BidIt r_end) { - bool boolsame=false; BidIt marked;//for r BidIt r_marked; BidIt n_marked; @@ -242,7 +241,6 @@ inline bool prev_combination( Prediate Equal) { - bool boolsame=false; BidIt marked;//for r BidIt r_marked; BidIt n_marked; diff --git a/RecoMuon/L3TrackFinder/interface/L3MuonTrajectoryBuilder.h b/RecoMuon/L3TrackFinder/interface/L3MuonTrajectoryBuilder.h index 565161fd58318..ee38ced5a037f 100644 --- a/RecoMuon/L3TrackFinder/interface/L3MuonTrajectoryBuilder.h +++ b/RecoMuon/L3TrackFinder/interface/L3MuonTrajectoryBuilder.h @@ -35,6 +35,7 @@ class L3MuonTrajectoryBuilder : public GlobalTrajectoryBuilderBase { /// destructor ~L3MuonTrajectoryBuilder(); /// reconstruct trajectories from standalone and tracker only Tracks + using GlobalTrajectoryBuilderBase::trajectories; MuonTrajectoryBuilder::CandidateContainer trajectories(const TrackCand&); /// pass the Event to the algo at each event virtual void setEvent(const edm::Event&); diff --git a/RecoParticleFlow/PFTracking/interface/PFElecTkProducer.h b/RecoParticleFlow/PFTracking/interface/PFElecTkProducer.h index bba80948a067e..18189f6e3c9b9 100644 --- a/RecoParticleFlow/PFTracking/interface/PFElecTkProducer.h +++ b/RecoParticleFlow/PFTracking/interface/PFElecTkProducer.h @@ -131,7 +131,6 @@ class PFElecTkProducer : public edm::stream::EDProducer<> { bool modemomentum_; bool applySel_; bool applyGsfClean_; - bool useFifthStep_; bool useFifthStepForEcalDriven_; bool useFifthStepForTrackDriven_; // bool useFifthStepSec_; diff --git a/RecoTracker/TkMSParametrization/interface/MSLayer.h b/RecoTracker/TkMSParametrization/interface/MSLayer.h index 25baca2625384..295a5ffa82320 100644 --- a/RecoTracker/TkMSParametrization/interface/MSLayer.h +++ b/RecoTracker/TkMSParametrization/interface/MSLayer.h @@ -71,7 +71,7 @@ class MSLayer { DataX0 theX0Data; - friend struct MSLayersKeeper; + friend class MSLayersKeeper; friend std::ostream& operator<<( std::ostream& s, const MSLayer & l); }; diff --git a/RecoVertex/TertiaryTracksVertexFinder/interface/ConfigurableTertiaryTracksVertexFinder.h b/RecoVertex/TertiaryTracksVertexFinder/interface/ConfigurableTertiaryTracksVertexFinder.h index 536836e35c36a..4ff230fb142d4 100644 --- a/RecoVertex/TertiaryTracksVertexFinder/interface/ConfigurableTertiaryTracksVertexFinder.h +++ b/RecoVertex/TertiaryTracksVertexFinder/interface/ConfigurableTertiaryTracksVertexFinder.h @@ -27,6 +27,7 @@ class ConfigurableTertiaryTracksVertexFinder : public VertexReconstructor { virtual ~ConfigurableTertiaryTracksVertexFinder(); + using VertexReconstructor::vertices; virtual std::vector vertices(const std::vector &) const; diff --git a/RecoVertex/TertiaryTracksVertexFinder/interface/TertiaryTracksVertexFinder.h b/RecoVertex/TertiaryTracksVertexFinder/interface/TertiaryTracksVertexFinder.h index 4be96f1609f09..be6ab39ea2170 100644 --- a/RecoVertex/TertiaryTracksVertexFinder/interface/TertiaryTracksVertexFinder.h +++ b/RecoVertex/TertiaryTracksVertexFinder/interface/TertiaryTracksVertexFinder.h @@ -12,6 +12,7 @@ class TertiaryTracksVertexFinder : public VertexReconstructor { virtual ~TertiaryTracksVertexFinder(); + using VertexReconstructor::vertices; virtual std::vector vertices(const std::vector & tracks) const { return theFinder->vertices(tracks); diff --git a/RecoVertex/TertiaryTracksVertexFinder/src/GetLineCovMatrix.cc b/RecoVertex/TertiaryTracksVertexFinder/src/GetLineCovMatrix.cc index 859e05974a892..7b18e475f6b0e 100644 --- a/RecoVertex/TertiaryTracksVertexFinder/src/GetLineCovMatrix.cc +++ b/RecoVertex/TertiaryTracksVertexFinder/src/GetLineCovMatrix.cc @@ -37,13 +37,13 @@ GlobalError GetLineCovMatrix::GetMatrix(GlobalPoint PointThree) { // the linear equation is K = PointOne + (PointTwo-PointOne)*s double s; - if( !fabs(PointTwo.x() - PointOne.x()) < 0.00000001 ) + if( !(fabs(PointTwo.x() - PointOne.x()) < 0.00000001) ) s = (PointThree.x() - PointOne.x()) / (PointTwo.x() - PointOne.x()) ; else { - if( !fabs(PointTwo.y() - PointOne.y()) < 0.00000001 ) + if( !(fabs(PointTwo.y() - PointOne.y()) < 0.00000001) ) s = (PointThree.y() - PointOne.y()) / (PointTwo.y() - PointOne.y()) ; else { - if( !fabs(PointTwo.z() - PointOne.z()) < 0.00000001 ) + if( !(fabs(PointTwo.z() - PointOne.z()) < 0.00000001) ) s = (PointThree.z() - PointOne.z()) / (PointTwo.z() - PointOne.z()) ; else { GlobalError EmptyError(0, 0, 0, 0, 0, 0); diff --git a/SimCalorimetry/EcalElectronicsEmulation/bin/GenABIO.cc b/SimCalorimetry/EcalElectronicsEmulation/bin/GenABIO.cc index 8bcf96cfc4952..1dbdee73b6195 100644 --- a/SimCalorimetry/EcalElectronicsEmulation/bin/GenABIO.cc +++ b/SimCalorimetry/EcalElectronicsEmulation/bin/GenABIO.cc @@ -106,12 +106,6 @@ ssize_t getline (char **lineptr, size_t *n, FILE *fp) using namespace std; -/** Number of crystals along eta in barrel - */ -const static int nBarrelEtaBins = 170; -/** Number of crystals in a eta ring of the barrel - */ -const static int nBarrelPhiBins = 360; /** Range of the x-index of endcap crystals (xman-xmin+1). */ const static int nEndcapXBins = 100; @@ -127,12 +121,6 @@ const static int nSupercrystalXBins = nEndcapXBins/supercrystalEdge; /** Range of endcap supercrystal y-index (ymay-ymin+1) */ const static int nSupercrystalYBins = nEndcapYBins/supercrystalEdge; -/** Number of trigger tower along eta in the barrel - */ -const static int nBarrelTowerEtaBins = nBarrelEtaBins/5; -/** Number of trigger tower in a eta ring of the barrel - */ -const static int nBarrelTowerPhiBins = nBarrelPhiBins/5; /** Number of endcap, obviously tow */ const static int nEndcaps = 2; @@ -163,7 +151,6 @@ const int nABTCCCh = 12;//nbr of TCC inputs on an AB const int nDCCCh = 12;//nbr of DCC outputs on an AB const int nTCCInEta = 6; //nbr of TCC bins along eta const int nAB = nABInPhi*nABInEta; -const int nTTInABAlongEta=nTTInEta/nABInEta; const int nTTInABAlongPhi=nTTInPhi/nABInPhi; const int iTTEtaMin[nABInEta] = {0,11,28,45}; const int iTTEtaMax[nABInEta] = {10,27,44,55}; diff --git a/TopQuarkAnalysis/TopJetCombination/bin/TtSemiLRJetComb_PurityLoop.cpp b/TopQuarkAnalysis/TopJetCombination/bin/TtSemiLRJetComb_PurityLoop.cpp index c1a567ff8a60c..80e0e513a4e93 100644 --- a/TopQuarkAnalysis/TopJetCombination/bin/TtSemiLRJetComb_PurityLoop.cpp +++ b/TopQuarkAnalysis/TopJetCombination/bin/TtSemiLRJetComb_PurityLoop.cpp @@ -28,7 +28,6 @@ const int nrFiles = 51; const TString path = "dcap://maite.iihe.ac.be:/pnfs/iihe/becms/heyninck/TtSemiMuEvents_TopRex_Juni/TtSemiMuEvents_"; //matching variables -const bool useSpaceAngle = true; const double SumAlphaCut = 0.7; //select which observables to use diff --git a/TopQuarkAnalysis/TopSkimming/src/TtDecayChannelSelector.cc b/TopQuarkAnalysis/TopSkimming/src/TtDecayChannelSelector.cc index 91760167ad135..082a8675eab97 100644 --- a/TopQuarkAnalysis/TopSkimming/src/TtDecayChannelSelector.cc +++ b/TopQuarkAnalysis/TopSkimming/src/TtDecayChannelSelector.cc @@ -7,9 +7,6 @@ // TtDecayChannelSelector::search functions static const std::string kGenParticles = "genParticles"; -// number of top branches for decay selection -static const unsigned int kTopBranches = 2; - // maximal number of possible leptonic decay // channels static const unsigned int kDecayChannels = 3; diff --git a/TrackingTools/GeomPropagators/src/AnalyticalImpactPointExtrapolator.cc b/TrackingTools/GeomPropagators/src/AnalyticalImpactPointExtrapolator.cc index 3191c571554c8..651e1ab1c5368 100644 --- a/TrackingTools/GeomPropagators/src/AnalyticalImpactPointExtrapolator.cc +++ b/TrackingTools/GeomPropagators/src/AnalyticalImpactPointExtrapolator.cc @@ -10,7 +10,7 @@ // #include "CommonDet/DetUtilities/interface/DetailedDetTimer.h" AnalyticalImpactPointExtrapolator::AnalyticalImpactPointExtrapolator (const MagneticField* field) : - thePropagator(new AnalyticalPropagator(theField, anyDirection)), + thePropagator(new AnalyticalPropagator(field, anyDirection)), theField(field) {} diff --git a/Validation/RecoTau/plugins/DQMHistPlotter.cc b/Validation/RecoTau/plugins/DQMHistPlotter.cc index 24f3fd87cf621..2271227a34105 100644 --- a/Validation/RecoTau/plugins/DQMHistPlotter.cc +++ b/Validation/RecoTau/plugins/DQMHistPlotter.cc @@ -21,7 +21,6 @@ #include //defaults for cfgEntryProcess -const double defaultScaleFactor = 1.; const std::string type_smMC = "smMC"; const std::string type_bsmMC = "bsmMC"; const std::string type_smSumMC = "smSumMC"; @@ -85,9 +84,6 @@ const std::string defaultDrawOptionLegend = "lpf"; const std::string drawOption_eBand = "eBand"; -// defaults for cfgEntryDrawJob -const bool defaultDoOverlayPlots = false; - // global defaults const int defaultCanvasSizeX = 800; const int defaultCanvasSizeY = 600;