Version française
Home     About     Download     Resources     Contact us    
Browse thread
let rec x = lazy x
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Mackenzie Straight <eizneckam@g...>
Subject: Re: [Caml-list] let rec x = lazy x
On 1/11/06, Alessandro Baretta <a.baretta@barettadeit.com> wrote:
> Strange as it may seem, it seems to work! With -rectypes enabled of course.
>
> Obviously, forcing x does not produce anything sensible, but it does produce
> something. Am I justified in believing that the result is a long chain of
> lazy-blocks, the last one containing a Stack_overflow exception?

http://caml.inria.fr/pub/docs/manual-ocaml/libref/Lazy.html

You don't want to do this.