Skip to content

Remove const_cast from TrackDepositInCaloTool

Susumu Oda requested to merge oda/athena:master-TrackDepositInCaloTool into master

http://goetz.web.cern.ch/goetz/mutable_2019-07-13.html#Calo_Other

nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +383
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

   381	  double phiMax       = phiPar+phiWidth;
   382	  // --- Fill vecHash ---
   383	  CaloCell_ID::CaloSample sample = const_cast<CaloDetDescriptor*>(descr)->getSampling();
   384	
   385	  std::vector<IdentifierHash> vecHash;
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +742
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

   740	    bool eLossFound        = false;
   741	    const CaloDetDescriptor* descr = it->second;
   742	    CaloCell_ID::CaloSample sample = const_cast<CaloDetDescriptor*>(descr)->getSampling();
   743	    ATH_MSG_VERBOSE("Analysing crossing of calo sample " << sample << " ");
   744	
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +776
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

   774	          if (paramMiddle) {
   775	            // Get energy:
   776	            // CaloCell_ID::CaloSample sample = const_cast<CaloDetDescriptor*>(descr)->getSampling();
   777	            const CaloCell* cell = getClosestCell(paramMiddle, descr);
   778	            if (cell) {
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +782
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

   780	              ETDeposit     = cell->et();
   781	            }
   782	            // energyDeposit = DepositInCell(const_cast<CaloDetDescriptor*>(descr)->getSampling(), paramMiddle->eta(), paramMiddle->momentum().phi(), 0.1);
   783	            // --- Extrapolate to exit of layer ---
   784	            Trk::Surface* surfExit = createSurface(descr, Exit);
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +896
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

   894	  for (const CaloDetDescriptor* descr : m_caloDDM->calo_descriptors_range()) {
   895	    if (descr) {
   896	      CaloCell_ID::CaloSample sample = const_cast<CaloDetDescriptor*>(descr)->getSampling();      
   897	      ATH_MSG_VERBOSE("Detector Description element for sample " << sample);
   898	      if ( descr->is_lar_em_barrel() ) {
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +929
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

   927	  for (const CaloDetDescriptor* descr : m_caloDDM->tile_descriptors_range()) {
   928	    if (descr) {
   929	      ATH_MSG_VERBOSE("Detector Description element for sample " << const_cast<CaloDetDescriptor*>(descr)->getSampling());
   930	      if (!descr->is_tile() ) {
   931	        ATH_MSG_VERBOSE("This is not a isTile()==true element.");
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +933
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

   931	        ATH_MSG_VERBOSE("This is not a isTile()==true element.");
   932	      }
   933	      CaloCell_ID::CaloSample sample = const_cast<CaloDetDescriptor*>(descr)->getSampling();
   934	      if (sample >= 15 && sample <= 17) {
   935	        // --- Skip the TileGap detector elements ---
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +1194
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

  1192	const CaloCell* TrackDepositInCaloTool::getClosestCellLAr(const Trk::TrackParameters* par, const CaloDetDescriptor* descr, const CaloCellContainer* caloCellCont) const {
  1193	
  1194	  CaloCell_ID::CaloSample sample = const_cast<CaloDetDescriptor*>(descr)->getSampling();
  1195	  // ATH_MSG_INFO("Sampling = " << sample);
  1196	  const CaloDetDescrElement* cellDescr = m_caloDDM->get_element(sample, par->position().eta(), par->position().phi());
nightly/master/2019-07-13T2149:Reconstruction/MuonIdentification/CaloTrkMuIdTools/src/TrackDepositInCaloTool.cxx +1225
2dc54597b7182154747b7175cd309c7a01c71e62	2019-05-20_T1458	Christos Anastopoulos	ParticleCaloCellAssociationTool ATLASRECTS-4679
68b3a8f721452d33f308ab20fe063b3334c479ac	2019-04-18_T1825	Jovan Mitrevski	More work on making extrapolator private in track to calo extension

  1223	  double phiMax       = phiPar+phiWidth;
  1224	  // --- Fill vecHash ---
  1225	  CaloCell_ID::CaloSample sample = const_cast<CaloDetDescriptor*>(descr)->getSampling();
  1226	
  1227	  std::vector<IdentifierHash> vecHash;

RunTier0Tests.py was fine. RunTier0Tests.log

Edited by Susumu Oda

Merge request reports

Loading