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 UAA03212 for caml-red; Thu, 8 Feb 2001 20:02:14 +0100 (MET) 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 NAA01056 for ; Thu, 8 Feb 2001 13:50:38 +0100 (MET) Received: from mercury.optrak.co.uk ([193.82.56.54]) by concorde.inria.fr (8.11.1/8.10.0) with ESMTP id f18CobX25425 for ; Thu, 8 Feb 2001 13:50:37 +0100 (MET) Received: by mercury.optrak.co.uk with Internet Mail Service (5.5.1960.3) id <1PQ8W11J>; Thu, 8 Feb 2001 12:50:39 -0000 Message-ID: <30273167BD5AD111A5AD00A0C992201725868D@mercury.optrak.co.uk> From: Serguei Ouklonski To: caml-list@inria.fr Subject: Optional arguments Date: Thu, 8 Feb 2001 12:50:37 -0000 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.1960.3) Content-Type: text/plain Sender: weis@pauillac.inria.fr Hi, Example1: let fn1 a:string (?b = "") = (String.length a) + (String.length b) let x = fn1 "test" result is function Example2: let fn1 (?a = "") b:string = (String.length a) + (String.length b) let x = fn1 "test" result is 4 (number) It seems that in both cases result should be 4. Have I missed something from OCaml docs? Regards Serguei Ouklonski