Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] OO runtime calling Random.int.
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: David Brown <caml-list@d...>
Subject: [Caml-list] OO runtime calling Random.int.
I eventually figured out today that the ocaml runtime is calling
Random.int inside of CamlinternalOO.choose.  This was causing the
bahavior of my program to change when I added new classes (specifically,
when I would inherit).  I fixed it in this case, by calling Random.init
later on in initialization.

My real question is when can this be called?  Is this something that
will only happen during startup of a given module, or can it happen
later?

Thanks,
Dave Brown

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners