Added the namespace eo for the global variable rng in eoRNG.cpp
Also added "using eo::rng" in eoRNG.h so nothing has to be modified. We should gradually move to write eo::rng everywhere, and remove that using directive to be almost full-proofed against possible name collision.
This commit is contained in:
parent
4b83dbd0f4
commit
61a85582d5
2 changed files with 9 additions and 0 deletions
|
|
@ -3,5 +3,8 @@
|
|||
|
||||
/// The global object, should probably be initialized with an xor
|
||||
/// between time and process_id.
|
||||
namespace eo
|
||||
{
|
||||
eoRng rng((uint32) time(0));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -279,7 +279,13 @@ private :
|
|||
/**
|
||||
The one and only global eoRng object
|
||||
*/
|
||||
namespace eo
|
||||
{
|
||||
extern eoRng rng;
|
||||
}
|
||||
|
||||
using eo::rng;
|
||||
|
||||
|
||||
// Implementation of some eoRng members.... Don't mind the mess, it does work.
|
||||
|
||||
|
|
|
|||
Reference in a new issue