Re: [Caml-list] [ANN] ocamlopen 1.0.2

2012-04-12 Thread Gabriel Scherer
Is there a description somewhere of the semantics of your language change? More specifically: 1. You link to a paper by Andres Löh and Ralf Hinze, how close are you of their proposal? They mention open datatypes and functions, you propose open datatypes, but not open functions? That would be

Re: [Caml-list] [ANN] ocamlopen 1.0.2

2012-04-12 Thread Alain Frisch
On 04/12/2012 04:16 PM, Philippe Veber wrote: Isn't this a good use case for polymorphic variants too ? I don't see how to use polymorphic variants here. The message bus itself need to provide functions like: val dispatch: message - unit val register_listener: (message - unit) - unit

Re: [Caml-list] [ANN] ocamlopen 1.0.2

2012-04-12 Thread Leo P White
1. You link to a paper by Andres Löh and Ralf Hinze, how close are you of their proposal? They mention open datatypes and functions, you propose open datatypes, but not open functions? That would be understandable because open pattern matching is a bit fishy (best-fit matching etc...). I think

Re: [Caml-list] [ANN] ocamlopen 1.0.2

2012-04-12 Thread Alain Frisch
On 04/12/2012 07:07 PM, Leo P White wrote: Just like exceptions, they are represented as constructors whose first field points to an address that is allocated by the extension definition to represent that extension. They have a special tag value so that structural equality knows to compare the

Re: [Caml-list] [ANN] ocamlopen 1.0.2

2012-04-12 Thread Leo P White
On Apr 12 2012, Alain Frisch wrote: Do we really need a new special tag? Why not use Object_tag and represent slots as blocks of size 2 (constructor name + unique integer as the second field)? This would have the following consequences (which are the expected ones): I hadn't really

[Caml-list] [ANN] ocamlopen 1.0.2

2012-04-11 Thread Leo P White
Hi, If anyone is interested, I have written a new version of my patch to add open extensible types to OCaml. It is available at: https://sites.google.com/site/ocamlopen/ The only new feature is allowing variant declarations to be made extensible. This allows declarations like: open type