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 VAA02097; Fri, 16 Apr 2004 21:01:37 +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 VAA13886 for ; Fri, 16 Apr 2004 21:01:35 +0200 (MET DST) Received: from smtp1.adl2.internode.on.net (smtp1.adl2.internode.on.net [203.16.214.181]) by concorde.inria.fr (8.12.10/8.12.10) with ESMTP id i3GJ1WYM030143 for ; Fri, 16 Apr 2004 21:01:34 +0200 Received: from [192.168.1.200] (ppp117-65.lns1.syd2.internode.on.net [150.101.117.65]) by smtp1.adl2.internode.on.net (8.12.9/8.12.9) with ESMTP id i3GIxjZq044516; Sat, 17 Apr 2004 04:29:46 +0930 (CST) Subject: Re: [Caml-list] help From: skaller Reply-To: skaller@users.sourceforge.net To: mohammad siddiqui Cc: rich@annexia.org, caml-list In-Reply-To: References: Content-Type: text/plain Message-Id: <1082141984.20063.184.camel@pelican.wigram> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.2 (1.2.2-4) Date: 17 Apr 2004 04:59:45 +1000 Content-Transfer-Encoding: 7bit X-Miltered: at concorde by Joe's j-chkmail ("http://j-chkmail.ensmp.fr")! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 sourceforge:01 2004:99 pointers:01 struct:01 isspace:01 isspace:01 9660:01 glebe:01 ocaml:01 ocaml:01 int:01 int:01 nsw:01 snail:02 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Sat, 2004-04-17 at 04:04, mohammad siddiqui wrote: > Hi, > I started the conversion project after completely getting hold of ocaml but > I still have some concerns like how we can manage pinters and pointer to > pointers, Generally you don't need them. Here is an example: in C: struct ilist { list *next; int v; }; In Ocaml: type ilist = Cons of int * ilist | Empty The * there means 'tuple' not pointer, in Ocaml everything except an int is already a pointer. > some functions in C like exit(), isspace(). exception Exit The Exit exception is not raised by any library function. It is provided for use in your programs. isspace is easy to implement: let isspace = function | ' ' | '\t' -> true | _ -> false -- John Skaller, mailto:skaller@users.sf.net voice: 061-2-9660-0850, snail: PO BOX 401 Glebe NSW 2037 Australia Checkout the Felix programming language http://felix.sf.net ------------------- 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