Re: [Caml-list] Parser/lexer for block indented code

2010-02-02 Thread blue storm
There is The Whitespace Thing : http://people.csail.mit.edu/mikelin/ocaml+twt/ I have tried to reproduce something similar using Camlp4 twice, the first time with a ad-hoc grammar reusing as much as the current grammar as possible, the second with the specific goal of compatibility with the F#

Re: [Caml-list] Parser/lexer for block indented code

2010-02-02 Thread Yoann Padioleau
On Feb 1, 2010, at 11:33 PM, Andrej Bauer wrote: Would anyone happen to have lying around parser/lexer for block indented code (a la Python and Haskell)? I am using ocamlyacc or menhir, whichever. There was some discussions about this in the past:

Re: [Caml-list] Parser/lexer for block indented code

2010-02-02 Thread blue storm
Yes, it appears I have a bit over-interpreted the question. Parsers for generic indentation-meaningful languages (not OCaml) have been discussed there. In particular, Andreas Rossberg has a working lexer in the layoutLexer.ml file of http://www.mpi-sws.org/~rossberg/hocaml-0.12.tgz

Re: [Caml-list] New to Ocaml

2010-02-02 Thread Richard Jones
On Mon, Feb 01, 2010 at 11:18:07PM -0500, chaithanya kr wrote: Hi all. I am new to Ocaml. Just started learning recently. There's also a beginners group for learning OCaml: Beginner's list: http://groups.yahoo.com/group/ocaml_beginners Rich. -- Richard Jones Red Hat

Re: [Caml-list] debugging memory leaks

2010-02-02 Thread Richard Jones
On Thu, Jan 28, 2010 at 08:34:13PM -0800, warrensomebody wrote: I know this is an old thread, but I have revised the memprof patch to work with ocaml-3.11.2. Please let me know if there is a maintainer who would like to look this over and/or distribute it. Otherwise, I'll put it up on github

[Caml-list] Re: debugging memory leaks

2010-02-02 Thread Sylvain Le Gall
On 29-01-2010, warrensomebody warrensomeb...@gmail.com wrote: I know this is an old thread, but I have revised the memprof patch to work with ocaml-3.11.2. Please let me know if there is a maintainer who would like to look this over and/or distribute it. Otherwise, I'll put it up on github or

[Caml-list] Thread safe heterogenous property lists (dictionaries)

2010-02-02 Thread Daniel Bünzli
Hello, I needed an implementation of heterogenous property lists [1] --- hereafter dictionaries. There's some code floating around on the www (e.g. here [2]) but it uses a thread unsafe implementation of universal types. This makes it unacceptably ugly as thread safety is not even guaranteed

[Caml-list] out of memory error

2010-02-02 Thread Kihong Heo
Hello caml list. I'm suffering out of memory problem. My program makes large graphs, but I didn't expect they need so much memory like that. (I'm not sure there is the infinite loop or not..) Can't I use ocamlrun -v for my program such that it use foreign language interface with C. If I

Re: [Caml-list] Thread safe heterogenous property lists (dictionaries)

2010-02-02 Thread Alain Frisch
On 02/02/2010 14:12, Daniel Bünzli wrote: The second one uses Maps for logarithmic time lookups. Operations on dictionaries are thread safe. However key creation is not because unique ids need to be generated for them. FWIW, a thread-safe way to generate fresh ids is: let fresh_id () = Oo.id

[Caml-list] [ANNOUNCE] New releases of Ocsigen server, Eliom and O'Browser

2010-02-02 Thread Vincent Balat
New releases are available for some of our software: - Ocsigen server version 1.3.0 - Eliom version 1.3.0 - O'Browser version 1.1 You can download them from http://ocsigen.org . Packages should be available soon in distributions. * Ocsigen server is a full featured Web server written in