English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
[Caml-list] Breaking out of iterative loops
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Markus Mottl <markus@o...>
Subject: Re: [Caml-list] Breaking out of iterative loops
On Wed, 01 May 2002, John Prevost wrote:
> The drawback to allowing:
> let rec ones = 1 :: ones
> and such expressions is that when looking at the definition of, for
> example, 'a list and length, one would expect it to be guaranteed that
> length terminates.  Since you can't prevent recursive use of
> constructors, well, you can no longer guarantee that.

I second this. Does anybody here really benefit from such cyclic

I haven't found a single practical case where this was useful, but would
assume that some future program transformation tools that use proofs by
induction would have an easier life if this were disallowed...

Markus Mottl

Markus Mottl                                             markus@oefai.at
Austrian Research Institute
for Artificial Intelligence                  http://www.oefai.at/~markus
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