Hello, can you suggest me some how to learn these topics?
The Event
module is a straightforward port to OCaml of Reppy’s Concurrent ML. Supposedly a good place to learn more about it is his book “Concurrent Programming in ML”.
Cheers,
Nicolás
I find the concept of Event
s and functionality provided by the module very useful, but I think that Event
is rarely used. Do you happen to know why?
A good treatment of the topic is in the OCaml O’Reilly book: in English, in French.
[everything below is from quite-possibly-faulty memories, so please take it with a grain of salt]
My memory is that Xavier wrote that as a demonstration of the possibility of implementing CML-style events in OCaml. But also that the implementation did not have the same GC-safety properties that CML-in-SML had; to wit, it would be possible to create hung-but-not-GCable threads, b/c CML relied upon properties of the SML GC in order to achieve its GC-friendly properties.
This isn’t important for small examples, but when using CML-style events for serious systems, it becomes an issue (again, IIRC).