From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 15312BC6B for ; Wed, 27 Jun 2007 10:42:27 +0200 (CEST) Received: from hades.snarc.org (hades.snarc.org [212.85.152.11]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l5R8gOgG028500 for ; Wed, 27 Jun 2007 10:42:26 +0200 Received: by hades.snarc.org (Postfix, from userid 1000) id 1FC6E1B4D7; Wed, 27 Jun 2007 10:34:02 +0200 (CEST) Date: Wed, 27 Jun 2007 10:34:02 +0200 From: Vincent Hanquez To: Jonathan Bryant Cc: =?iso-8859-1?Q?Qu=F4c?= Peyrot , caml-list@inria.fr Subject: Re: [Caml-list] precision not working properly for strings in Printf? Message-ID: <20070627083401.GA32745@snarc.org> References: <0AC5F6BF-D076-4561-B015-70E41954D248@lrde.epita.fr> <7A72D27B-4FF3-4483-8D42-B9904FA734E2@valdosta.edu> <86507DD0-1BCB-4BF9-A058-0809022E564C@lrde.epita.fr> <8503CBAB-EF9E-4CF0-89A8-2F6E454CF4DC@valdosta.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8503CBAB-EF9E-4CF0-89A8-2F6E454CF4DC@valdosta.edu> X-Warning: Email may contain unsmilyfied humor and/or satire. User-Agent: Mutt/1.5.13 (2006-08-11) X-Miltered: at discorde with ID 468222F0.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; printf:01 ocaml:01 printf:01 scanf:01 ocaml:01 compiler:01 wrappers:01 cheers:01 wrote:01 glibc:01 glibc:01 caml-list:01 functions:01 strings:01 modules:02 On Wed, Jun 27, 2007 at 12:11:01AM -0400, Jonathan Bryant wrote: > The OCaml standard library isn't glibc. The implementation of the > Printf/Scanf modules is custom, OCaml specific and tied into the > compiler, so one should not assume the behave the same way. They are > not simply wrappers. As a matter of fact, they have several other > differences from the glibc printf family of functions (look at the > conversion specifiers in the docs). > > >As said above, this is not how printf is working in the glibc (at > >least on linux and Mac OS X). Any clue why the same convention has > >not been followed? > > See above. What about reading before replying ? Your "explanation" certainly doesn't answer his question. whether or not it's the same *implementation* doesn't answer why ocaml printf choosed a different *convention* (specially on this case which I don't see any contradiction in the way ocaml works). Cheers, -- Vincent Hanquez