Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
CLHEP
CLHEP
Commits
a71be94a
Commit
a71be94a
authored
Jun 12, 2015
by
Lynn Garren
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change implementation of static methods dealing with static data
parent
4b2582a5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
6 deletions
+25
-6
ChangeLog
ChangeLog
+12
-2
Random/Random/RandGauss.h
Random/Random/RandGauss.h
+4
-4
Random/src/RandGauss.cc
Random/src/RandGauss.cc
+9
-0
No files found.
ChangeLog
View file @
a71be94a
2015-06-12 Lynn Garren <garren@fnal.gov>
* Random/Random/RandGauss.h, Random/src/RandGauss.cc:
implement static methods dealing with static data
in RandGauss.cc instead of in RandGauss.h
* protect against warnings in Utility/memory.h and Utility/type_traits.h
==============================
27.06.11 Release CLHEP-2.2.0.7
==============================
2015-06-10 Lynn Garren <garren@fnal.gov>
* do not add -Wno-deprecated-declarations when building for c++NN
* protect against warnings in Utility/memory.h
* do not use -Wno-deprecated-declarations when building for c++NN
* __attribute__((unused)) is not recognized by Visual C++
* Make sure asserts are enabled for tests by removing -DNDEBUG
from the compiler flags when building the tests. This solves
...
...
Random/Random/RandGauss.h
View file @
a71be94a
...
...
@@ -110,9 +110,9 @@ public:
// code before shoot/fire will force generation of a new couple of
// values.
static
bool
getFlag
()
{
return
set_st
;}
static
bool
getFlag
()
;
static
void
setFlag
(
bool
val
)
{
set_st
=
val
;}
static
void
setFlag
(
bool
val
)
;
bool
getF
()
const
{
return
set
;}
...
...
@@ -144,9 +144,9 @@ public:
protected:
static
double
getVal
()
{
return
nextGauss_st
;}
static
double
getVal
()
;
static
void
setVal
(
double
nextVal
)
{
nextGauss_st
=
nextVal
;}
static
void
setVal
(
double
nextVal
)
;
double
normal
();
...
...
Random/src/RandGauss.cc
View file @
a71be94a
...
...
@@ -58,6 +58,15 @@ double RandGauss::operator()( double mean, double stdDev ) {
return
fire
(
mean
,
stdDev
);
}
// implement static methods dealing with static data here
bool
RandGauss
::
getFlag
()
{
return
set_st
;}
void
RandGauss
::
setFlag
(
bool
val
)
{
set_st
=
val
;}
double
RandGauss
::
getVal
()
{
return
nextGauss_st
;}
void
RandGauss
::
setVal
(
double
nextVal
)
{
nextGauss_st
=
nextVal
;}
double
RandGauss
::
shoot
()
{
// Gaussian random numbers are generated two at the time, so every other
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment