Skip to content

Commit

Permalink
clang check RecoBTau
Browse files Browse the repository at this point in the history
  • Loading branch information
davidlange6 committed Oct 8, 2017
1 parent 5349f79 commit 0cf3507
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions RecoBTau/JetCrystalsAssociator/src/JetCrystalsAssociator.cc
Expand Up @@ -68,10 +68,10 @@ class JetCrystalsAssociator : public edm::EDProducer {

public:
explicit JetCrystalsAssociator(const edm::ParameterSet&);
~JetCrystalsAssociator();
~JetCrystalsAssociator() override;


virtual void produce(edm::Event&, const edm::EventSetup&) override;
void produce(edm::Event&, const edm::EventSetup&) override;
private:
std::unique_ptr<JetCrystalsAssociationCollection> associate(
const edm::Handle<CaloJetCollection> & jets,
Expand Down Expand Up @@ -164,7 +164,7 @@ JetCrystalsAssociator::produce(edm::Event& iEvent, const edm::EventSetup& iSetup
DetId id = theRecHit->detid();
const CaloCellGeometry* this_cell = EB->getGeometry(id);
if (this_cell) {
GlobalPoint posi = this_cell->getPosition();
const GlobalPoint& posi = this_cell->getPosition();
double energy = theRecHit->energy();
double eta = posi.eta();
double phi = posi.phi();
Expand All @@ -183,7 +183,7 @@ JetCrystalsAssociator::produce(edm::Event& iEvent, const edm::EventSetup& iSetup
DetId id = theRecHit->detid();
const CaloCellGeometry* this_cell = EE->getGeometry(id);
if (this_cell) {
GlobalPoint posi = this_cell->getPosition();
const GlobalPoint& posi = this_cell->getPosition();
double energy = theRecHit->energy();
double eta = posi.eta();
double phi = posi.phi();
Expand Down
6 changes: 3 additions & 3 deletions RecoBTau/JetTagComputer/interface/GenericMVAJetTagComputer.h
Expand Up @@ -16,11 +16,11 @@ class JetTagComputerRecord;
class GenericMVAJetTagComputer : public JetTagComputer {
public:
GenericMVAJetTagComputer(const edm::ParameterSet &parameters);
virtual ~GenericMVAJetTagComputer();
~GenericMVAJetTagComputer() override;

virtual void initialize(const JetTagComputerRecord &);
void initialize(const JetTagComputerRecord &) override;

virtual float discriminator(const TagInfoHelper &info) const;
float discriminator(const TagInfoHelper &info) const override;

virtual reco::TaggingVariableList
taggingVariables(const reco::BaseTagInfo &tagInfo) const;
Expand Down
Expand Up @@ -24,7 +24,7 @@ class JetTagComputerESProducer: public edm::ESProducer {
m_jetTagComputer = std::make_shared<ConcreteJetTagComputer>(m_pset);
}

virtual ~JetTagComputerESProducer() {
~JetTagComputerESProducer() override {
}

std::shared_ptr<JetTagComputer> produce(const JetTagComputerRecord & record) {
Expand Down
2 changes: 1 addition & 1 deletion RecoBTau/JetTagComputer/plugins/JetTagProducer.cc
Expand Up @@ -132,7 +132,7 @@ JetTagProducer::produce(Event& iEvent, const EventSetup& iSetup)
// take first tagInfo
Handle< View<BaseTagInfo> > &tagInfoHandle = tagInfoHandles[0];
std::unique_ptr<JetTagCollection> jetTagCollection;
if (tagInfoHandle.product()->size() > 0) {
if (!tagInfoHandle.product()->empty()) {
RefToBase<Jet> jj = tagInfoHandle->begin()->jet();
jetTagCollection = std::make_unique<JetTagCollection>(edm::makeRefToBaseProdFrom(jj, iEvent));
} else
Expand Down
4 changes: 2 additions & 2 deletions RecoBTau/JetTagComputer/plugins/JetTagProducer.h
Expand Up @@ -22,11 +22,11 @@
class JetTagProducer : public edm::stream::EDProducer<> {
public:
explicit JetTagProducer(const edm::ParameterSet&);
~JetTagProducer();
~JetTagProducer() override;
static void fillDescriptions(edm::ConfigurationDescriptions & descriptions);

private:
virtual void produce(edm::Event&, const edm::EventSetup&);
void produce(edm::Event&, const edm::EventSetup&) override;

std::string m_jetTagComputer;
std::vector<edm::EDGetTokenT<edm::View<reco::BaseTagInfo> > > token_tagInfos;
Expand Down
2 changes: 1 addition & 1 deletion RecoBTau/JetTagComputer/src/GenericMVAComputerCache.cc
Expand Up @@ -52,7 +52,7 @@ GenericMVAComputer const* GenericMVAComputerCache::getComputer(int index) const
<< "Calibration record " << errorUpdatingLabel
<< " not found in MVAComputerContainer." << std::endl;
}
return index >= 0 ? computers[index].computer.get() : 0;
return index >= 0 ? computers[index].computer.get() : nullptr;
}

bool GenericMVAComputerCache::isEmpty() const {
Expand Down

0 comments on commit 0cf3507

Please sign in to comment.