From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by yquem.inria.fr (Postfix) with ESMTP id B2597BBAF for ; Fri, 15 Oct 2010 12:22:43 +0200 (CEST) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvUFAJ/It0zVujhf/2dsb2JhbACTJo17cb0ShUkEjU4 X-IronPort-AV: E=Sophos;i="4.57,335,1283724000"; d="scan'208";a="73686035" Received: from witko.kerneis.info ([213.186.56.95]) by mail4-smtp-sop.national.inria.fr with ESMTP/TLS/AES256-SHA; 15 Oct 2010 12:22:23 +0200 Received: from [134.157.168.130] (helo=rhodium.pps.jussieu.fr) by witko.kerneis.info with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1P6hPt-0003O2-S4; Fri, 15 Oct 2010 12:21:37 +0200 Received: from kerneis by rhodium.pps.jussieu.fr with local (Exim 4.72) (envelope-from ) id 1P6hPj-0001DQ-G7; Fri, 15 Oct 2010 12:21:27 +0200 Date: Fri, 15 Oct 2010 12:21:27 +0200 From: Gabriel Kerneis To: dumitru.potop@inria.fr Cc: caml-list@inria.fr Subject: Re: [Caml-list] Smart caml editor and smart debugger Message-ID: <20101015102127.GD27290@rhodium.pps.jussieu.fr> References: <4CB8210D.7030307@inria.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4CB8210D.7030307@inria.fr> User-Agent: Mutt/1.5.20 (2009-06-14) X-SA-Exim-Connect-IP: 134.157.168.130 X-SA-Exim-Mail-From: kerneis@pps.jussieu.fr X-SA-Exim-Scanned: No (on witko.kerneis.info); SAEximRunCond expanded to false X-Spam: no; 0.00; debugger:01 0200,:01 toplevel:01 wrote:01 rec:01 pps:01 caml-list:01 functions:01 jussieu:01 int:01 int:01 caml:02 parameters:03 let:03 fri:05 On Fri, Oct 15, 2010 at 11:38:21AM +0200, Dumitru Potop-Butucaru wrote: > Is there some tool allowing me, for instance, > to choose the functions whose calls I want to trace? > (so that the call and its parameters are > automatically logged). In a toplevel, use the #trace directive: # let rec f x = if x = 0 then 42 else f (x-1);; value f : int -> int = # #trace f;; f is now traced. # f 3 ;; f <-- 3 f <-- 2 f <-- 1 f <-- 0 f --> 42 f --> 42 f --> 42 f --> 42 - : int = 42 Best, -- Gabriel