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 MAA04798; Sat, 31 Jul 2004 12:24:43 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id MAA05824 for ; Sat, 31 Jul 2004 12:24:42 +0200 (MET DST) X-SPAM-Warning: Sending machine is listed in blackholes.five-ten-sg.com Received: from m14s26.vip-server.net (cray.gaillourdet.net [80.190.204.60]) by nez-perce.inria.fr (8.12.10/8.12.10) with ESMTP id i6VAOfEV028539 for ; Sat, 31 Jul 2004 12:24:41 +0200 Received: from dijkstra.gaillourdet.net (m14s26.vip-server.net [80.190.204.60]) by m14s26.vip-server.net (Postfix) with ESMTP id D5A6294CFF for ; Sat, 31 Jul 2004 12:23:24 +0200 (CEST) Received: by dijkstra.gaillourdet.net (Postfix, from userid 1000) id 9DAE451693; Sat, 31 Jul 2004 12:24:38 +0200 (CEST) From: Jean-Marie Gaillourdert To: caml-list@inria.fr Subject: Re: [Caml-list] const equivalent for mutable types? Date: Sat, 31 Jul 2004 12:24:38 +0200 User-Agent: KMail/1.6.2 References: <410B5EBD.6060800@cgorski.org> <200407311124.06799.jmg@gaillourdet.net> In-Reply-To: <200407311124.06799.jmg@gaillourdet.net> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200407311224.38221.jmg@gaillourdet.net> X-Miltered: at nez-perce with ID 410B7369.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; jean-marie:99 caml-list:01 const:01 31.:99 2004:99 const:01 jean-marie:99 compiler:01 mutable:01 schrieb:01 complex:03 types:03 trick:03 let:04 let:04 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk Hi, > Am Samstag, 31. Juli 2004 10:56 schrieb Christopher A. Gorski: > > The problem is that in complex programs I often get confused over what > > functions are modifying values and what functions are not. I feel like > > I should be able to do something like > > > > let result = change (const r) > > > > and have the compiler give me a type error. let const = (!) will do the trick. Regards, Jean-Marie Gaillourdet ------------------- 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