Skip to content

Commit

Permalink
Merge pull request #43752 from smuzaffar/fix-warn-ig1
Browse files Browse the repository at this point in the history
Fix warnings which are ignored by bot
  • Loading branch information
cmsbuild authored Jan 23, 2024
2 parents 743099a + 2bfaabc commit 884233d
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 11 deletions.
6 changes: 4 additions & 2 deletions Alignment/CocoaFit/src/Fit.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1210,8 +1210,9 @@ void Fit::dumpFittedValues(ALIFileOut& fileout, ALIbool printErrors, ALIbool pri
// const Entry* entry;
int ii, siz;
std::vector<OpticalObject*>::const_iterator vocite;
ALIstring sys = ALIstring("system");
for (vocite = Model::OptOList().begin(); vocite != Model::OptOList().end(); ++vocite) {
if ((*vocite)->type() == ALIstring("system"))
if ((*vocite)->type() == sys)
continue;

fileout << " %%%% Optical Object: " << (*vocite)->longName() << std::endl;
Expand Down Expand Up @@ -1268,8 +1269,9 @@ void Fit::dumpFittedValuesInAllAncestorFrames(ALIFileOut& fileout, ALIbool print
//---------- Iterate over OptO list
std::vector<Entry*> entries;
std::vector<OpticalObject*>::const_iterator vocite;
ALIstring sys = ALIstring("system");
for (vocite = Model::OptOList().begin(); vocite != Model::OptOList().end(); ++vocite) {
if ((*vocite)->type() == ALIstring("system"))
if ((*vocite)->type() == sys)
continue;

fileout << " %%%% Optical Object: " << (*vocite)->longName() << std::endl;
Expand Down
5 changes: 2 additions & 3 deletions Alignment/CocoaToDDL/src/UnitConverter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
#include "Alignment/CocoaToDDL/interface/CocoaUnitsTable.h"
#include "CLHEP/Units/GlobalSystemOfUnits.h"
#include <sstream>
#include <strstream>

/*
UnitConverter::UnitConverter(const G4BestUnit & bu)
Expand All @@ -23,7 +22,7 @@ UnitConverter::UnitConverter(ALIdouble val, const ALIstring& category)
UnitConverter::~UnitConverter() { delete bu_; }

std::string UnitConverter::ucstring() {
std::ostrstream str;
std::ostringstream str;

if (angl_) {
str.precision(11);
Expand All @@ -42,7 +41,7 @@ std::string UnitConverter::ucstring() {
/*
ostream & operator<<(ostream & os, const UnitConverter & uc)
{
ostrstream temp;
std::ostringstream temp;
//temp << uc.bu_;
//temp << '\0';
//string s(temp.str());
Expand Down
5 changes: 2 additions & 3 deletions Alignment/CocoaUtilities/src/ALIFileIn.cc
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
#include "Alignment/CocoaUtilities/interface/ALIFileIn.h"

#include <cstdlib>
#include <strstream>
//#include <strstream.h>
#include <sstream>

//#include <algo.h>

Expand Down Expand Up @@ -112,7 +111,7 @@ ALIint ALIFileIn::getWordsInLine(std::vector<ALIstring>& wordlist) {
}

//---------- Convert line read to istrstream to split it in words
std::istrstream istr_line(ltemp);
std::istringstream istr_line(ltemp);

//--------- count how many words are there in ltemp (this sohuld not be needed, but sun compiler has problems) !! this has to be nvestigated...
ALIint NoWords = 0;
Expand Down
2 changes: 1 addition & 1 deletion Alignment/CocoaUtilities/src/ALIFileOut.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include "Alignment/CocoaUtilities/interface/ALIFileOut.h"

#include <cstdlib>
#include <strstream>
#include <sstream>

std::vector<ALIFileOut*> ALIFileOut::theInstances;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
#include <vector>
#include <iostream>
#include <fstream>
#include <ext/hash_map>

class SiStripBadModuleByHandBuilder : public ConditionDBWriter<SiStripBadStrip> {
public:
Expand Down
2 changes: 1 addition & 1 deletion DQM/HcalTasks/plugins/UMNioTask.cc
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ UMNioTask::UMNioTask(edm::ParameterSet const& ps)
}

int UMNioTask::getOrbitGapIndex(uint8_t eventType, uint32_t laserType) {
constants::OrbitGapType orbitGapType;
constants::OrbitGapType orbitGapType = tNull;
if (eventType == constants::EVENTTYPE_PHYSICS) {
orbitGapType = tPhysics;
} else if (eventType == constants::EVENTTYPE_PEDESTAL) {
Expand Down

0 comments on commit 884233d

Please sign in to comment.