Skip to content

Commit

Permalink
Merge pull request #28810 from smuzaffar/llvm9-errors
Browse files Browse the repository at this point in the history
[LLVM 9] Fixed build errors
  • Loading branch information
cmsbuild committed Jan 30, 2020
2 parents 7f1d6e0 + dcdf62c commit dc86c99
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ class MillePedeFileReader {

const std::array<std::string, 8> coord_str = {{"X", "Y", "Z", "theta_X", "theta_Y", "theta_Z", "extra_DOF", "none"}};
inline std::ostream& operator<<(std::ostream& os, const AlignPCLThresholds::coordType& c) {
if (c >= AlignPCLThresholds::endOfTypes || c < 0)
if (c >= AlignPCLThresholds::endOfTypes || c < AlignPCLThresholds::X)
return os << "unrecongnized coordinate";
return os << coord_str[c];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ class EnergyScaleCorrection_class {
void ReadSmearingFromFile(TString filename); ///< File structure: category constTerm alpha;
public:
inline void SetSmearingType(fileFormat_t value) {
if (value >= 0 && value <= 1) {
if (value <= 1) {
smearingType_ = value;
} else {
smearingType_ = UNKNOWN;
Expand Down
2 changes: 1 addition & 1 deletion HLTrigger/JetMET/src/HLTJetSortedVBFFilter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ bool HLTJetSortedVBFFilter<T>::hltFilter(edm::Event& event,
nJet++;
// cout << "jetPt=" << jet->pt() << "\tjetEta=" << jet->eta() << "\tjetCSV=" << value << endl;
}
if (b1_idx >= sorted.size() || b1_idx < 0)
if (b1_idx >= sorted.size())
edm::LogError("OutOfRange") << "b1 index out of range.";
sorted.erase(sorted.begin() + b1_idx); //remove the most b-tagged jet from "sorted"
sort(sorted.begin(), sorted.end(), comparator); //sort "sorted" by eta
Expand Down
2 changes: 1 addition & 1 deletion RecoEgamma/EgammaTools/src/EnergyScaleCorrection.cc
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ void EnergyScaleCorrection::addSmearing(const std::string& category,
}

void EnergyScaleCorrection::setSmearingType(FileFormat value) {
if (value >= 0 && value <= 1) {
if (value <= 1) {
smearingType_ = value;
} else {
smearingType_ = UNKNOWN;
Expand Down
2 changes: 0 additions & 2 deletions RecoTauTag/RecoTau/plugins/DPFIsolation.cc
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,6 @@ class DPFIsolation : public deep_tau::DeepTauBase {

if (p.pt() < 0.5)
continue;
if (p.fromPV() < 0)
continue;
if (deltaR_tau_p > 0.5)
continue;
if (p.fromPV() < 1 && p.charge() != 0)
Expand Down

0 comments on commit dc86c99

Please sign in to comment.