Skip to content

Commit

Permalink
[RECONSTRUCTION] Changes suggested by new llvm18 clang-format
Browse files Browse the repository at this point in the history
  • Loading branch information
smuzaffar committed Sep 5, 2024
1 parent 15ea9bb commit a09aaae
Show file tree
Hide file tree
Showing 394 changed files with 712 additions and 718 deletions.
4 changes: 2 additions & 2 deletions CommonTools/Clustering1D/interface/Clustering1DException.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@

class Clustering1DException : public cms::Exception {
public:
Clustering1DException(const char *reason) : cms::Exception(reason){};
Clustering1DException(const Clustering1DException &ex) : cms::Exception(ex){};
Clustering1DException(const char *reason) : cms::Exception(reason) {}
Clustering1DException(const Clustering1DException &ex) : cms::Exception(ex) {}
};

#endif
2 changes: 1 addition & 1 deletion CommonTools/Clustering1D/interface/Clusterizer1D.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
template <class T>
class Clusterizer1D {
public:
virtual ~Clusterizer1D(){};
virtual ~Clusterizer1D() {}
virtual std::pair<std::vector<Cluster1D<T> >, std::vector<const T*> > operator()(
const std::vector<Cluster1D<T> >&) const = 0;

Expand Down
2 changes: 1 addition & 1 deletion CommonTools/Clustering1D/interface/WeightEstimator.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class WeightEstimator {
virtual double weight(const std::vector<const T*>&) const = 0;
virtual WeightEstimator* clone() const = 0;

virtual ~WeightEstimator(){};
virtual ~WeightEstimator() {}
};

#endif
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

class PFCandWithSuperClusterExtractor : public reco::isodeposit::IsoDepositExtractor {
public:
PFCandWithSuperClusterExtractor(){};
PFCandWithSuperClusterExtractor() {}
PFCandWithSuperClusterExtractor(const edm::ParameterSet &par, edm::ConsumesCollector &&iC);

~PFCandWithSuperClusterExtractor() override {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
class PFCandidateMuonUntagger : public edm::global::EDProducer<> {
public:
PFCandidateMuonUntagger(const edm::ParameterSet &);
~PFCandidateMuonUntagger() override{};
~PFCandidateMuonUntagger() override {}

void produce(edm::StreamID iID, edm::Event &, const edm::EventSetup &) const override;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ struct HFChannel {
class PFCandidateRecalibrator : public edm::stream::EDProducer<> {
public:
PFCandidateRecalibrator(const edm::ParameterSet&);
~PFCandidateRecalibrator() override{};
~PFCandidateRecalibrator() override {}

static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);

Expand Down
2 changes: 1 addition & 1 deletion CommonTools/ParticleFlow/plugins/PFMuonUntagger.cc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
class PFMuonUntagger : public edm::global::EDProducer<> {
public:
PFMuonUntagger(const edm::ParameterSet &);
~PFMuonUntagger() override{};
~PFMuonUntagger() override {}

void produce(edm::StreamID iID, edm::Event &, const edm::EventSetup &) const override;

Expand Down
2 changes: 1 addition & 1 deletion CommonTools/RecoAlgos/src/MuonSelector.cc
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ namespace helper {
trk.setExtra(TrackExtraRef(rSATrackExtras_, isadx_++));

} // SA trkRef.isNonnull()
} // end of track, and function
} // end of track, and function

//-------------------------------------------------------------------------
//! Check if all references to silicon strip/pixel clusters are available.
Expand Down
4 changes: 2 additions & 2 deletions CommonTools/Statistics/interface/StatisticsException.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@

class StatisticsException : public cms::Exception {
public:
StatisticsException(const char *reason) : cms::Exception(reason){};
StatisticsException(const StatisticsException &ex) : cms::Exception(ex){};
StatisticsException(const char *reason) : cms::Exception(reason) {}
StatisticsException(const StatisticsException &ex) : cms::Exception(ex) {}
};

#endif
2 changes: 1 addition & 1 deletion CommonTools/UtilAlgos/interface/InputTagDistributor.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class InputTagDistributorService {
InputTagDistributorService(const edm::ParameterSet& iConfig, edm::ActivityRegistry& r) {
r.watchPreModuleConstruction(this, &InputTagDistributorService::preModule);
};
~InputTagDistributorService(){};
~InputTagDistributorService() {}

InputTagDistributor& init(std::string user, const edm::ParameterSet& iConfig, edm::ConsumesCollector&& iC) {
if (multipleInstance_.find(user) != multipleInstance_.end()) {
Expand Down
2 changes: 1 addition & 1 deletion CommonTools/UtilAlgos/interface/OverlapExclusionSelector.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ template <typename C, typename T, typename O>
class OverlapExclusionSelector {
public:
OverlapExclusionSelector(const edm::ParameterSet& cfg, edm::ConsumesCollector&& iC)
: OverlapExclusionSelector(cfg, iC){};
: OverlapExclusionSelector(cfg, iC) {}
OverlapExclusionSelector(const edm::ParameterSet& cfg, edm::ConsumesCollector& iC);
void newEvent(const edm::Event&, const edm::EventSetup&) const;
bool operator()(const T&) const;
Expand Down
12 changes: 6 additions & 6 deletions CommonTools/Utils/interface/ExpressionEvaluatorTemplates.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,19 @@ namespace reco {
template <typename Ret, typename... Args>
struct genericExpression {
virtual Ret operator()(Args...) const = 0;
virtual ~genericExpression(){};
virtual ~genericExpression() {}
};

template <typename Object>
struct CutOnObject {
virtual bool eval(Object const&) const = 0;
virtual ~CutOnObject(){};
virtual ~CutOnObject() {}
};

template <typename Object>
struct ValueOnObject {
virtual double eval(Object const&) const = 0;
virtual ~ValueOnObject(){};
virtual ~ValueOnObject() {}
};

template <typename Object>
Expand All @@ -38,7 +38,7 @@ namespace reco {
cands.begin(), cands.end(), mask.begin(), [&](typename Collection::value_type const& c) { return f(*c); });
}
virtual void eval(Collection const&, Mask&) const = 0;
virtual ~MaskCollection(){};
virtual ~MaskCollection() {}
};

template <typename Object>
Expand All @@ -51,7 +51,7 @@ namespace reco {
cands.end());
}
virtual void eval(Collection&) const = 0;
virtual ~SelectInCollection(){};
virtual ~SelectInCollection() {}
};

template <typename Object>
Expand All @@ -68,7 +68,7 @@ namespace reco {
}
}
virtual void eval(Collection const&, Indices&) const = 0;
virtual ~SelectIndecesInCollection(){};
virtual ~SelectIndecesInCollection() {}
};

} // namespace reco
Expand Down
2 changes: 1 addition & 1 deletion CommonTools/Utils/src/FormulaEvaluator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ namespace {

class FunctionFinder : public ExpressionElementFinderBase {
public:
FunctionFinder(ExpressionFinder const* iEF) : m_expressionFinder(iEF){};
FunctionFinder(ExpressionFinder const* iEF) : m_expressionFinder(iEF) {}

bool checkStart(char iSymbol) const final { return std::isalpha(iSymbol); }

Expand Down
2 changes: 1 addition & 1 deletion DataFormats/BTauReco/interface/CombinedTauTagInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ namespace reco {
theECALEt_o_leadTkPt = NAN;
theHCALEt_o_leadTkPt = NAN;
}
~CombinedTauTagInfo() override{};
~CombinedTauTagInfo() override {}

// float discriminator() returns 0. if candidate did not pass tracker selection,
// 1. if candidate passed tracker selection and did not contain neutral ECAL clus.,
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/BTauReco/interface/VertexTypes.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ namespace reco {
std::string name(VertexType);
VertexType type(const std::string&);
} // namespace Vertices
} // namespace btag
} // namespace btag
} // namespace reco

#endif
4 changes: 2 additions & 2 deletions DataFormats/Candidate/interface/Candidate.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ namespace reco {
typedef unsigned int index;

/// default constructor
Candidate(){};
Candidate() {}
/// destructor
virtual ~Candidate();
/// electric charge
Expand Down Expand Up @@ -176,7 +176,7 @@ namespace reco {
/// this function can be used to set the ptr to the source of the
/// Candidate, which will allow to keep track
/// of the reconstruction history.
virtual void setSourceCandidatePtr(const CandidatePtr& ptr){};
virtual void setSourceCandidatePtr(const CandidatePtr& ptr) {}

/// chi-squares
virtual double vertexChi2() const = 0;
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/DTRecHit/interface/DTChamberRecSegment2D.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class DTChamberRecSegment2D : public DTRecSegment2D {
std::vector<DTRecHit1D> &hits1D);

/// Destructor
~DTChamberRecSegment2D() override{};
~DTChamberRecSegment2D() override {}

/* Operations */

Expand Down
4 changes: 2 additions & 2 deletions DataFormats/DTRecHit/interface/DTSLRecSegment2D.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
class DTSLRecSegment2D : public DTRecSegment2D {
public:
/// Constructor
DTSLRecSegment2D(){};
DTSLRecSegment2D() {}

/// c'tor from hits
DTSLRecSegment2D(const DTSuperLayerId id, const std::vector<DTRecHit1D> &hits);
Expand All @@ -29,7 +29,7 @@ class DTSLRecSegment2D : public DTRecSegment2D {
std::vector<DTRecHit1D> &hits1D);

/// Destructor
~DTSLRecSegment2D() override{};
~DTSLRecSegment2D() override {}

// Operations

Expand Down
6 changes: 3 additions & 3 deletions DataFormats/EgammaCandidates/interface/GsfElectron.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ namespace reco {
const TrackRef &closestCtfTrack,
const TrackBaseRef &conversionPartner,
const GsfTrackRefVector &ambiguousTracks) const;
~GsfElectron() override{};
~GsfElectron() override {}

private:
void init();
Expand Down Expand Up @@ -512,7 +512,7 @@ namespace reco {
struct SaturationInfo {
int nSaturatedXtals;
bool isSeedSaturated;
SaturationInfo() : nSaturatedXtals(0), isSeedSaturated(false){};
SaturationInfo() : nSaturatedXtals(0), isSeedSaturated(false) {}
};

// accessors
Expand Down Expand Up @@ -680,7 +680,7 @@ namespace reco {
sumPhotonEtHighThreshold(0),
sumPUPt(0),
sumEcalClusterEt(0),
sumHcalClusterEt(0){};
sumHcalClusterEt(0) {}
};

struct MvaInput {
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/EgammaCandidates/interface/Photon.h
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ namespace reco {
struct SaturationInfo {
int nSaturatedXtals;
bool isSeedSaturated;
SaturationInfo() : nSaturatedXtals(0), isSeedSaturated(false){};
SaturationInfo() : nSaturatedXtals(0), isSeedSaturated(false) {}
};

// accessors
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/EgammaReco/interface/PreshowerCluster.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ namespace reco {
typedef math::XYZPoint Point;

/// default constructor
PreshowerCluster() : CaloCluster(0., Point(0., 0., 0.)){};
PreshowerCluster() : CaloCluster(0., Point(0., 0., 0.)) {}

~PreshowerCluster() override;

Expand Down
2 changes: 1 addition & 1 deletion DataFormats/EgammaReco/interface/PreshowerClusterShape.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ namespace reco {
class PreshowerClusterShape {
public:
/// default constructor
PreshowerClusterShape(){};
PreshowerClusterShape() {}

virtual ~PreshowerClusterShape();

Expand Down
4 changes: 2 additions & 2 deletions DataFormats/EgammaReco/src/SuperCluster.cc
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ SuperCluster::SuperCluster(double energy,
for (std::vector<std::pair<DetId, float> >::const_iterator diIt = v1.begin(); diIt != v1.end(); ++diIt) {
hitsAndFractions_.push_back((*diIt));
} // loop over rechits
} // loop over basic clusters
} // loop over basic clusters

computeRawEnergy();
}
Expand Down Expand Up @@ -70,7 +70,7 @@ SuperCluster::SuperCluster(double energy,
for (std::vector<std::pair<DetId, float> >::const_iterator diIt = v1.begin(); diIt != v1.end(); ++diIt) {
hitsAndFractions_.push_back((*diIt));
} // loop over rechits
} // loop over basic clusters
} // loop over basic clusters

// set references to preshower clusters
for (CaloClusterPtrVector::const_iterator pcit = preshowerClusters.begin(); pcit != preshowerClusters.end(); ++pcit) {
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/JetReco/interface/BasicJet.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ namespace reco {
BasicJet(const LorentzVector& fP4, const Point& fVertex);
BasicJet(const LorentzVector& fP4, const Point& fVertex, const Jet::Constituents& fConstituents);

~BasicJet() override{};
~BasicJet() override {}

/// Polymorphic clone
BasicJet* clone() const override;
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/JetReco/interface/CaloJet.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ namespace reco {
/** backward compatible, vertex=(0,0,0) */
CaloJet(const LorentzVector& fP4, const Specific& fSpecific, const Jet::Constituents& fConstituents);

~CaloJet() override{};
~CaloJet() override {}

/** Returns the maximum energy deposited in ECAL towers*/
float maxEInEmTowers() const { return m_specific.mMaxEInEmTowers; }
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/JetReco/interface/GenJet.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ namespace reco {
/** backward compatible, vertex=(0,0,0) */
GenJet(const LorentzVector& fP4, const Specific& fSpecific, const Jet::Constituents& fConstituents);

~GenJet() override{};
~GenJet() override {}
/** Returns energy of electromagnetic particles*/
float emEnergy() const { return m_specific.m_EmEnergy; };
/** Returns energy of hadronic particles*/
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/JetReco/interface/JPTJet.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ namespace reco {
/** backward compatible, vertex=(0,0,0) */
JPTJet(const LorentzVector& fP4, const Specific& fSpecific, const Jet::Constituents& fConstituents);

~JPTJet() override{};
~JPTJet() override {}
/// chargedHadronEnergy
float chargedHadronEnergy() const { return mspecific.mChargedHadronEnergy; }
/// chargedHadronEnergyFraction
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/JetReco/interface/PFJet.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ namespace reco {
/** backward compatible, vertex=(0,0,0) */
PFJet(const LorentzVector& fP4, const Specific& fSpecific, const Jet::Constituents& fConstituents);

~PFJet() override{};
~PFJet() override {}

/// chargedHadronEnergy
float chargedHadronEnergy() const { return m_specific.mChargedHadronEnergy; }
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/JetReco/src/Jet.cc
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ namespace {
double r() const { return mR; }

private:
CaloPointZ(){};
CaloPointZ() {}
double mZ;
double mR;
};
Expand Down
4 changes: 2 additions & 2 deletions DataFormats/Math/interface/approx_math.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ namespace approx_math {
// not c++ compliant (only C compliant)
// to be c++ compliaint one must use memcpy...
union binary32 {
constexpr binary32() : ui32(0){};
constexpr binary32(float ff) : f(ff){};
constexpr binary32() : ui32(0) {}
constexpr binary32(float ff) : f(ff) {}
constexpr binary32(int32_t ii) : i32(ii) {}
constexpr binary32(uint32_t ui) : ui32(ui) {}

Expand Down
2 changes: 1 addition & 1 deletion DataFormats/MuonReco/interface/MuonIsolation.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ namespace reco {
trackerVetoPt(0),
emVetoEt(0),
hadVetoEt(0),
hoVetoEt(0){};
hoVetoEt(0) {}
};
} // namespace reco
#endif
2 changes: 1 addition & 1 deletion DataFormats/MuonReco/interface/MuonTrackLinks.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ namespace reco {
: theTkTrack(tk), theStaTrack(sta), theGlbTrack(glb) {}

/// Destructor
virtual ~MuonTrackLinks(){};
virtual ~MuonTrackLinks() {}

// Operations

Expand Down
8 changes: 4 additions & 4 deletions DataFormats/MuonReco/src/MuonSelectors.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1002,10 +1002,10 @@ int muon::sharedSegments(const reco::Muon& mu, const reco::Muon& mu2, unsigned i
(segmentMatch->dtSegmentRef.isNonnull() && segmentMatch->dtSegmentRef == segmentMatch2->dtSegmentRef)) {
++ret;
} // is the same
} // segment of mu2 in chamber
} // segment of mu1 in chamber
} // chamber of mu2
} // chamber of mu1
} // segment of mu2 in chamber
} // segment of mu1 in chamber
} // chamber of mu2
} // chamber of mu1

return ret;
}
Expand Down
Loading

0 comments on commit a09aaae

Please sign in to comment.