From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id TAA03901 for caml-red; Thu, 27 Jul 2000 19:38:44 +0200 (MET DST) Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id OAA30015 for ; Wed, 26 Jul 2000 14:58:29 +0200 (MET DST) Received: from tobago.inria.fr (tobago.inria.fr [128.93.8.21]) by concorde.inria.fr (8.10.0/8.10.0) with ESMTP id e6QCwSD12102 for ; Wed, 26 Jul 2000 14:58:28 +0200 (MET DST) Received: (from doligez@localhost) by tobago.inria.fr (8.6.10/8.6.6) id OAA10269 for caml-list@inria.fr; Wed, 26 Jul 2000 14:58:27 +0200 Date: Wed, 26 Jul 2000 14:58:27 +0200 From: Damien Doligez Message-Id: <200007261258.OAA10269@tobago.inria.fr> To: caml-list@inria.fr Subject: Re: automatic construction of mli files Sender: weis@pauillac.inria.fr >From: Jean-Christophe Filliatre >In the extreme situation where there is no real need for writing an >interface, you can either simply not write one (this is not mandatory) >or generate it from the code with "ocamlc -c -i". There are two technical details you should all know concerning .mli files: 1. If you don't use .mli files, or if you generate them automatically from the corresponding .ml files, then you lose separate compilation: whenever you change a semicolon in foo.ml, all the files that depend on module Foo will have to be recompiled. This may or may not be a big problem depending on the size of your project. 2. Due to rather complex implementation issues, if you don't use .mli files and let the compiler generate the .cmi from the .ml, then garbage collection will be slightly slower. If you do it for all your files, you might lose as much as 8% on the speed of your program. -- Damien