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 PAA27028; Thu, 11 Oct 2001 15:34:30 +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 PAA26750 for ; Thu, 11 Oct 2001 15:34:30 +0200 (MET DST) Received: from beaune.inria.fr (beaune.inria.fr [128.93.8.3]) by concorde.inria.fr (8.11.1/8.10.0) with ESMTP id f9BDYTb12924 for ; Thu, 11 Oct 2001 15:34:29 +0200 (MET DST) Received: by beaune.inria.fr (8.8.8/1.1.22.3/14Sep99-0328PM) id PAA0000014200; Thu, 11 Oct 2001 15:34:29 +0200 (MET DST) Date: Thu, 11 Oct 2001 15:34:29 +0200 (MET DST) From: Damien Doligez Message-Id: <200110111334.PAA0000014200@beaune.inria.fr> To: caml-list@inria.fr Subject: Re: [Caml-list] C style for loop Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk >At 2:47 PM +0200 11/10/01, Berke Durak wrote: >>Do you really pretend that ``C-style for loops'' have ``self-evident >>readability merits'' ?! My opinion is that ```C-style'' loop syntax >>IS unreadable, ununderstandable and unprovable. How many people using >>C know the _exact_ semantics of : >> >> for(exp1;expr2;expr3){expr4} >From: Bruce Hoult >Sure, it's easy: > > { > exp1; > while (expr2){ > expr4; > expr3; > } > } > >It's damn ugly, though, and with much unnecessary repetition of the >control variable in simple cases. It's incorrect, too. A "continue" statement within expr4 doesn't do the same thing in both versions. -- Damien ------------------- Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr