Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] non-exported functions
[ 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: Re: [Caml-list] non-exported functions
On Tue, Oct 28, 2003 at 11:52:03PM -0800, Dustin Sallings wrote:
> 
> On Oct 28, 2003, at 10:50 PM, Jean-Baptiste Rouquier wrote:
> 
> >>I kinda liked automatically generating my .mli,
> >ocamlc -i foo.ml > foo.mli
> 
> 	Right, like that.  If I have to make a custom mli, I have to take 
> 	this out of my build system.  :)

If you wanted to feel more Haskell-like, you could have your build
system search for some specially formatted comment with an exports line
in it.  That way you could declare the things you want to export, and
filter the output of ocamlc -i.  You also want to make sure you write
the output to a temporary file, and only overwrite the foo.mli if it has
changed, otherwise you will rebuild way too much.

Dave

-------------------
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