Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] why the "rec" in "let rec"?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Falk Hueffner <falk.hueffner@s...>
Subject: Re: [Caml-list] why the "rec" in "let rec"?
On Wed, 7 May 2003, Hal Daume III wrote:

> Arguably, the "simplest" way to dealing with:
>
> > let f x = ..
> > let f x = f x
>
> is to simply disallow bindings like this.  I would think that they're
> almost always a bug.

It is often useful in code like this:

  let g = Graph.make 6 3 1 in
  let g = Graph.set_immutable_vertex g 0 in
  let g = Graph.set_immutable_vertex g 4 in
  let g = Graph.set_connected g 0 1 in
  let g = Graph.set_connected g 0 3 in
 ...

(Real World Example! ;)

	Falk

-------------------
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