From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id VAA13281; Thu, 7 Oct 2004 21:45:21 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f 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 VAA12483 for ; Thu, 7 Oct 2004 21:45:20 +0200 (MET DST) Received: from nexus.stwing.upenn.edu (NEXUS.STWING.UPENN.EDU [165.123.132.61]) by concorde.inria.fr (8.13.0/8.13.0) with ESMTP id i97JjIbs024456 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL) for ; Thu, 7 Oct 2004 21:45:20 +0200 Received: from force.stwing.upenn.edu (force.stwing.upenn.edu [165.123.132.65]) by nexus.stwing.upenn.edu (8.12.10/8.12.9) with ESMTP id i97JjHHA027018 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL) for ; Thu, 7 Oct 2004 15:45:17 -0400 (EDT) Received: from force.stwing.upenn.edu (localhost [127.0.0.1]) by force.stwing.upenn.edu (8.12.10/8.12.9) with ESMTP id i97JjGh4004006 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 7 Oct 2004 15:45:16 -0400 (EDT) Received: (from wlovas@localhost) by force.stwing.upenn.edu (8.12.10/8.12.9/Submit) id i97JjGCg003963 for caml-list@inria.fr; Thu, 7 Oct 2004 15:45:16 -0400 (EDT) Date: Thu, 7 Oct 2004 15:45:15 -0400 From: William Lovas To: caml-list Subject: Re: [Caml-list] Do you like files as modules? Message-ID: <20041007194515.GB7219@force.stwing.upenn.edu> Mail-Followup-To: caml-list References: <1097118765.20680.565.camel@pelican.wigram> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1097118765.20680.565.camel@pelican.wigram> User-Agent: Mutt/1.5.4i X-Miltered: at concorde with ID 41659CCE.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; lovas:01 wlovas:01 stwing:01 caml-list:01 2004:99 python:01 model:01 degenerate:01 compiler:01 compiler:01 semantics:01 semantics:01 ocaml:01 folks:01 filesystem:02 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Thu, Oct 07, 2004 at 01:12:46PM +1000, skaller wrote: > In both Ocaml and Python, the module name is also > coupled to the filename. > > Which technique do you prefer? Why? What advantages > and disadvantages does each have? Some people say that it's a misstep to couple the programs semantics with that of the operating system's filesystem. Personally, however, i like being able to tell which file a function is defined in while i'm reading someone else's source code. Conventions go a long way, but language restrictions can't be ignored. Unfortunately, module *types* are not treated the same way, so you're forced to refer to things like Map.S and whatnot.. > How is the > compiler architectural model coupled to program > semantics, optimisation, separate compilation, > and linkage, and should it be? This is a tough question, i think, and I like the way the O'Caml folks have answered it. Standard ML gets around this question by *not* answering it, so every compiler implementation has its own idea of how to do things. This makes it hard (impossible?) to write Standard ML programs that build uniformly under any implementation of the language. (In some degenerate sense, i suppose the same is true of O'Caml, though, since it has only one implementation.) cheers, William ------------------- 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