Import Geant4 11.2.0 source tree
This commit is contained in:
@@ -6,6 +6,9 @@ It must **not** be used as a substitute for writing good git commit messages!
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
## 2023-10-27 Daren Sawkey (op-V11-01-00)
|
||||
- G4OpBoundaryProcess: verbosity of 0 silences run-time warnings
|
||||
|
||||
## 2022-11-23 Gabriele Cosmo (op-V11-00-08)
|
||||
- Fixed compilation warnings for implicit type conversions on macOS/XCode 14.1.
|
||||
|
||||
|
||||
@@ -232,7 +232,8 @@ class G4OpBoundaryProcess : public G4VDiscreteProcess
|
||||
|
||||
G4int f_iTE, f_iTM;
|
||||
|
||||
G4int fNumWarnings; // number of times small step warning printed
|
||||
G4int fNumSmallStepWarnings = 0; // number of times small step warning printed
|
||||
G4int fNumBdryTypeWarnings = 0; // number of times boundary type warning printed
|
||||
|
||||
size_t idx_dichroicX = 0;
|
||||
size_t idx_dichroicY = 0;
|
||||
|
||||
@@ -123,8 +123,6 @@ G4OpBoundaryProcess::G4OpBoundaryProcess(const G4String& processName,
|
||||
fRindex1 = fRindex2 = 1.;
|
||||
fSint1 = 0.;
|
||||
fDichroicVector = nullptr;
|
||||
|
||||
fNumWarnings = 0;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -206,9 +204,10 @@ G4VParticleChange* G4OpBoundaryProcess::PostStepDoIt(const G4Track& aTrack,
|
||||
}
|
||||
return G4VDiscreteProcess::PostStepDoIt(aTrack, aStep);
|
||||
}
|
||||
else if (stepLength <= 10.*fCarTolerance && fNumWarnings < 10)
|
||||
else if (stepLength <= 10.*fCarTolerance && fNumSmallStepWarnings < 10)
|
||||
{ // see bug 2510
|
||||
++fNumWarnings;
|
||||
++fNumSmallStepWarnings;
|
||||
if(verboseLevel > 0)
|
||||
{
|
||||
G4ExceptionDescription ed;
|
||||
ed << "G4OpBoundaryProcess: "
|
||||
@@ -216,7 +215,7 @@ G4VParticleChange* G4OpBoundaryProcess::PostStepDoIt(const G4Track& aTrack,
|
||||
<< "This is larger than the threshold " << fCarTolerance/mm << " mm "
|
||||
"to set status StepTooSmall." << G4endl
|
||||
<< "Boundary scattering may be incorrect. ";
|
||||
if(fNumWarnings == 10)
|
||||
if(fNumSmallStepWarnings == 10)
|
||||
{
|
||||
ed << G4endl << "*** Step size warnings stopped.";
|
||||
}
|
||||
@@ -511,9 +510,20 @@ G4VParticleChange* G4OpBoundaryProcess::PostStepDoIt(const G4Track& aTrack,
|
||||
}
|
||||
else
|
||||
{
|
||||
G4ExceptionDescription ed;
|
||||
ed << " PostStepDoIt(): Illegal boundary type." << G4endl;
|
||||
G4Exception("G4OpBoundaryProcess", "OpBoun04", JustWarning, ed);
|
||||
if(fNumBdryTypeWarnings <= 10)
|
||||
{
|
||||
++fNumBdryTypeWarnings;
|
||||
if(verboseLevel > 0)
|
||||
{
|
||||
G4ExceptionDescription ed;
|
||||
ed << " PostStepDoIt(): Illegal boundary type." << G4endl;
|
||||
if(fNumBdryTypeWarnings == 10)
|
||||
{
|
||||
ed << "** Boundary type warnings stopped." << G4endl;
|
||||
}
|
||||
G4Exception("G4OpBoundaryProcess", "OpBoun04", JustWarning, ed);
|
||||
}
|
||||
}
|
||||
return G4VDiscreteProcess::PostStepDoIt(aTrack, aStep);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user