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 TAA08129; Thu, 23 Oct 2003 19:39:29 +0200 (MET DST) 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 TAA32476 for ; Thu, 23 Oct 2003 19:39:28 +0200 (MET DST) Received: from mx1.mat.unb.br (mx1.mat.unb.br [164.41.38.4]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id h9NHdP112721 for ; Thu, 23 Oct 2003 19:39:25 +0200 (MET DST) Received: (from root@localhost) by mx1.mat.unb.br (8.11.6/8.11.6) id h9NHdHt07751 for caml-list@inria.fr; Thu, 23 Oct 2003 15:39:17 -0200 (BRST) (envelope-from flavio@mat.unb.br) Received: from localhost (flavio@localhost) by mx1.mat.unb.br (8.11.6/8.11.6av) with ESMTP id h9NHdGp07744 for ; Thu, 23 Oct 2003 15:39:16 -0200 (BRST) (envelope-from flavio@mat.unb.br) X-Authentication-Warning: mx1.mat.unb.br: flavio owned process doing -bs Date: Thu, 23 Oct 2003 15:39:15 -0200 (BRST) From: Flavio Leonardo Cavalcanti de Moura To: Subject: [Caml-list] actualize a string Message-ID: <20031023152601.U5169-100000@mx1.mat.unb.br> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE X-Virus-Scanned: by AMaViS perl-10 X-Loop: caml-list@inria.fr X-Spam: no; 0.00; unb:99 actualize:99 reductions:01 actualize:99 mat:01 ocaml:01 string:03 string:03 let:04 let:04 loop:06 problem:07 problem:07 manual:07 performed:10 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk =09I am trying to build a procedure such that some reductions are performed while a list (of redex) is not empty. The problem is that a new list is needed at each step otherwise it will loop for ever. The actual code is let normal exp =3D let l =3D exp :: [] in while (matchingApp exp [] []) <> [] do exp :=3D (appreduction exp (hd (matchingApp exp [] []))); exp :: l done; l;; After the 'while' I would like to actualize the expression 'exp' with the string (appreduction exp (hd (matchingApp exp [] []))). The problem is that with :=3D it does not work. How can I do that? I couldn't find anythin= g in the ocaml manual. =09Best regards, =09Fl=E1vio Leonardo. ------------------- 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