Skip to content

Commit

Permalink
StETofHitMaker: Fix unused variable warnings (star-bnl#471)
Browse files Browse the repository at this point in the history
```
g++ -m64 -fPIC -pipe -Wall -Woverloaded-virtual -std=c++0x -Wno-long-long -pthread -Wno-deprecated-declarations -O2 -g -falign-loops -falign-jumps -falign-functions -Dsl79_gcc485 -D__ROOT__ -DNEW_DAQ_READER -I. -IStRoot -I.sl79_gcc485/include -I/opt/software/linux-scientific7-x86_64/gcc-4.8.5/root-5.34.38-l3v6vso6qgojm4l2ctwjojs6trbt4hpn/include -c .sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.cxx -o .sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.o
.sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.cxx: In member function 'void StETofHitMaker::processStEvent()':
.sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.cxx:415:27: warning: unused variable 'etofHits' [-Wunused-variable]
         StSPtrVecETofHit& etofHits = etofCollection->etofHits();
                           ^
.sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.cxx: In member function 'void StETofHitMaker::processMuDst()':
.sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.cxx:485:16: warning: unused variable 'nHits' [-Wunused-variable]
         size_t nHits = mMuDst->numberOfETofHit();
                ^
.sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.cxx: In member function 'void StETofHitMaker::fillUnclusteredHitQA(const double&, bool)':
.sl79_gcc485/OBJ/StRoot/StETofHitMaker/StETofHitMaker.cxx:1203:9: warning: unused variable 'eventTime' [-Wunused-variable]
     int eventTime = ( this->GetTime() / 10000 ) * 3600 + ( ( this->GetTime() % 10000 ) / 100 ) * 60 + ( this->GetTime() % 100 );
         ^
```
  • Loading branch information
plexoos authored Dec 31, 2022
1 parent 51f7b58 commit 81d6a97
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 19 deletions.
18 changes: 0 additions & 18 deletions StRoot/StETofHitMaker/StETofHitMaker.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -412,14 +412,8 @@ StETofHitMaker::processStEvent()
}

if( etofCollection->hitsPresent() ) {
StSPtrVecETofHit& etofHits = etofCollection->etofHits();
//LOG_INFO << "processStEvent() - etof hit collection: " << etofHits.size() << " entries" << endm;

fillHitQA( isMuDst, tstart );
}
else {
// LOG_INFO << "processStEvent() - no hits" << endm;
}
}

//_____________________________________________________________
Expand Down Expand Up @@ -482,14 +476,8 @@ StETofHitMaker::processMuDst()


if( mMuDst->numberOfETofHit() ) {
size_t nHits = mMuDst->numberOfETofHit();
//LOG_INFO << "processMuDst() - etof hits: " << nHits << " entries" << endm;

fillHitQA( isMuDst, tstart );
}
else {
//LOG_INFO << "processMuDst() - no hits" << endm;
}
}
//_____________________________________________________________

Expand Down Expand Up @@ -1200,9 +1188,6 @@ StETofHitMaker::fillUnclusteredHitQA( const double& tstart, const bool isMuDst )

int nHitsPrinted = 0;

int eventTime = ( this->GetTime() / 10000 ) * 3600 + ( ( this->GetTime() % 10000 ) / 100 ) * 60 + ( this->GetTime() % 100 );
//LOG_INFO << "fillUnclusteredHitQA(): -- event time: " << eventTime << endm;

for( const auto& kv : mStoreHit ) {
unsigned int detIndex = kv.first;

Expand Down Expand Up @@ -1285,9 +1270,6 @@ StETofHitMaker::fillUnclusteredHitQA( const double& tstart, const bool isMuDst )
std::string histNamePosJump = "unclusteredHit_jump_pos_s" + std::to_string( sector ) + "m" + std::to_string( plane ) + "c" + std::to_string( counter );
if( hit->clusterSize() > 100 ) mHistograms.at( histNamePosJump )->Fill( hit->localX(), hit->localY() );

//std::string histNamePosTime = "unclusteredHit_pos_time_s" + std::to_string( sector ) + "m" + std::to_string( plane ) + "c" + std::to_string( counter );
//mHistograms.at( histNamePosTime )->Fill( eventTime, hit->localY() );

// ---------------------------------------
if( fabs( tstart + 9999. ) < 1.e-5 ) continue;

Expand Down
1 change: 0 additions & 1 deletion mgr/warnoff_dirs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ StRoot/StEEmcPool.*
StRoot/StEEmcSimulatorMaker
StRoot/StEEmcUtil
StRoot/StEStructPool.*
StRoot/StETofHitMaker
StRoot/StEmbeddingUtilities
StRoot/StEmcADCtoEMaker
StRoot/StEmcCalibrationMaker
Expand Down

0 comments on commit 81d6a97

Please sign in to comment.