> -----Ursprüngliche Nachricht----- > Von: Jon Harrop [mailto:jon@jdh30.plus.com] > Gesendet: Mittwoch, 15. September 2004 15:29 > An: caml-list@inria.fr > Betreff: [Caml-list] Confused > > > > How come this works: > > # let rec build = function 0 -> [] | n -> 1e-6 :: build > (n-1);; val build : int -> float list = # let test = 1. > :: build 1000;; val test : float list = ... > > But this does not: > > # let rec build = function 0 -> [] | n -> 1e-6 :: build (n-1) in > let test = 1. :: build 1000;; > Syntax error try let rec build = function 0 -> [] | n -> 1e-6 :: build (n-1) in let test = 1. :: build 1000 in test;; Regards, Christoph Bauer