Skip to content

Commit

Permalink
Merge pull request #10959 from gartung/CommonTools-RecoAlgos-fix-usin…
Browse files Browse the repository at this point in the history
…g-namespace

Fix for warning from clang static analyzer.
  • Loading branch information
davidlange6 committed Aug 27, 2015
2 parents b670908 + 6873b0c commit b700075
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions CommonTools/RecoAlgos/plugins/PrimaryVertexSorter.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,17 +76,14 @@ class PrimaryVertexSorter : public edm::stream::EDProducer<> {
#include "FWCore/Framework/interface/EventSetup.h"


using namespace std;
using namespace edm;
using namespace reco;

template <class ParticlesCollection>
PrimaryVertexSorter<ParticlesCollection>::PrimaryVertexSorter(const edm::ParameterSet& iConfig) :
assignmentAlgo_(iConfig.getParameterSet("assignment")),
sortingAlgo_(iConfig.getParameterSet("sorting")),
tokenCandidates_(consumes<ParticlesCollection>(iConfig.getParameter<InputTag>("particles"))),
tokenVertices_(consumes<VertexCollection>(iConfig.getParameter<InputTag>("vertices"))),
tokenJets_(consumes<edm::View<reco::Candidate> > (iConfig.getParameter<InputTag>("jets"))),
tokenCandidates_(consumes<ParticlesCollection>(iConfig.getParameter<edm::InputTag>("particles"))),
tokenVertices_(consumes<reco::VertexCollection>(iConfig.getParameter<edm::InputTag>("vertices"))),
tokenJets_(consumes<edm::View<reco::Candidate> > (iConfig.getParameter<edm::InputTag>("jets"))),
produceOriginalMapping_(iConfig.getParameter<bool>("produceAssociationToOriginalVertices")),
produceSortedVertices_(iConfig.getParameter<bool>("produceSortedVertices")),
producePFPileUp_(iConfig.getParameter<bool>("producePileUpCollection")),
Expand All @@ -95,6 +92,9 @@ PrimaryVertexSorter<ParticlesCollection>::PrimaryVertexSorter(const edm::Paramet
useMET_(iConfig.getParameter<bool>("usePVMET"))
{

using namespace std;
using namespace edm;
using namespace reco;

if(produceOriginalMapping_){
produces< CandToVertex> ("original");
Expand Down Expand Up @@ -130,8 +130,11 @@ PrimaryVertexSorter<ParticlesCollection>::PrimaryVertexSorter(const edm::Paramet


template <class ParticlesCollection>
void PrimaryVertexSorter<ParticlesCollection>::produce(Event& iEvent, const EventSetup& iSetup) {
void PrimaryVertexSorter<ParticlesCollection>::produce(edm::Event& iEvent, const edm::EventSetup& iSetup) {

using namespace std;
using namespace edm;
using namespace reco;

Handle<edm::View<reco::Candidate> > jets;
iEvent.getByToken( tokenJets_, jets);
Expand Down

0 comments on commit b700075

Please sign in to comment.