Import Geant4 10.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-10 11:51:14 +02:00
parent e2d2f9810a
commit 286caacf06
12421 changed files with 730077 additions and 502383 deletions
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id$
// $Id: B2TrackerHit.hh 69505 2013-05-07 01:57:27Z asaim $
//
/// \file B2TrackerHit.hh
/// \brief Definition of the B2TrackerHit class
@@ -35,6 +35,7 @@
#include "G4THitsCollection.hh"
#include "G4Allocator.hh"
#include "G4ThreeVector.hh"
#include "tls.hh"
/// Tracker hit class
///
@@ -84,22 +85,22 @@ class B2TrackerHit : public G4VHit
typedef G4THitsCollection<B2TrackerHit> B2TrackerHitsCollection;
extern G4Allocator<B2TrackerHit> B2TrackerHitAllocator;
extern G4ThreadLocal G4Allocator<B2TrackerHit>* B2TrackerHitAllocator;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline void* B2TrackerHit::operator new(size_t)
{
void *hit;
hit = (void *) B2TrackerHitAllocator.MallocSingle();
return hit;
if(!B2TrackerHitAllocator)
B2TrackerHitAllocator = new G4Allocator<B2TrackerHit>;
return (void *) B2TrackerHitAllocator->MallocSingle();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline void B2TrackerHit::operator delete(void *hit)
{
B2TrackerHitAllocator.FreeSingle((B2TrackerHit*) hit);
B2TrackerHitAllocator->FreeSingle((B2TrackerHit*) hit);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......