From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Pawel Newsgroups: gmane.emacs.help Subject: newbie: debugging elisp. Date: Wed, 24 May 2006 15:19:33 +0200 Message-ID: <17524.23909.801866.31018@gargle.gargle.HOWL> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1148476798 2704 80.91.229.2 (24 May 2006 13:19:58 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 24 May 2006 13:19:58 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed May 24 15:19:48 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FitH9-0006Jj-5G for geh-help-gnu-emacs@m.gmane.org; Wed, 24 May 2006 15:19:47 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FitH8-00084m-Ip for geh-help-gnu-emacs@m.gmane.org; Wed, 24 May 2006 09:19:46 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FitGx-00084b-97 for help-gnu-emacs@gnu.org; Wed, 24 May 2006 09:19:35 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FitGv-00084J-G1 for help-gnu-emacs@gnu.org; Wed, 24 May 2006 09:19:35 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FitGv-00084G-BO for help-gnu-emacs@gnu.org; Wed, 24 May 2006 09:19:33 -0400 Original-Received: from [212.77.101.1] (helo=smtp.wp.pl) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1FitLM-0007Xf-VE for help-gnu-emacs@gnu.org; Wed, 24 May 2006 09:24:09 -0400 Original-Received: (wp-smtpd smtp.wp.pl 12001 invoked from network); 24 May 2006 15:19:26 +0200 Original-Received: from jupiter.adlex.com (HELO ) (null7@[157.25.157.162]) (envelope-sender ) by smtp.wp.pl (WP-SMTPD) with SMTP for ; 24 May 2006 15:19:26 +0200 Original-To: emacs mailing list X-MAILER: KMail/1.7.1 X-WP-AV: skaner antywirusowy poczty Wirtualnej Polski S. A. X-WP-SPAM: NO AS1=NO(Body=1 Fuz1=1 Fuz2=1) AS2=NO(0.543094) AS3=NO AS4=NO X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:35225 Archived-At: Hallo In order to ask more precise questions related to problems with emacs packages I decided to learn a bit how to debug elisp programs. I started with edebug, because it also shows source code. I tried debugging emacs tramp package. I read three steps of edebug info pages, especially step about instrumenting the code. Unfortunatelly that manual is not clear for me. ----------- Problem 1: code instrumentation ----------- I did: 1) I set up in .emacs (setq edebug-trace t) (setq edebug-all-defs t) (setq edebug-all-forms t) 2) restarted emacs 3) visited tramp.el file 4) M-x eval-current-buffer Then I expected that call to any function that is in tramp.elc (I have compiled sources) will invoke debug. Unfortunatelly it did not stop even once. But when I figured out what is the actual tramp entry point (tramp-file-name-handler), and then invoked M-x edebug-defun on that function definition, and then rerun my tramp command, emacs execution stopped inside that method. My question is: a) Do I understand bad, the way eval-current-buffer works ? -------------- Problem 2: stepping into function ------------- As edebug stopped at tramp-file-name-handler, I stepped through that with . When I wanted to step into (`i') function called from tramp-file-name-handler, I got the (example) message: Don't know where tramp-find-foreign-file-name-handler is defined. tramp-find-foreign-file-name-handler is defined in the same file as tramp-file-name-handler (tramp.el). Could You tell me, what I am doing wrong Greetings