From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Marcin Borkowski Newsgroups: gmane.emacs.help Subject: Re: Advice on troubleshooting function to "unscroll" Date: Mon, 26 Jan 2015 00:15:53 +0100 Message-ID: <87vbjufo46.fsf@wmi.amu.edu.pl> References: <54C5577D.4030700@gmail.com> <871tmih6w0.fsf@wmi.amu.edu.pl> <54C56827.6030802@gmail.com> <54C5748E.4060605@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1422227781 5675 80.91.229.3 (25 Jan 2015 23:16:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 25 Jan 2015 23:16:21 +0000 (UTC) To: Drew Adams , help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jan 26 00:16:20 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YFWPk-000164-Hm for geh-help-gnu-emacs@m.gmane.org; Mon, 26 Jan 2015 00:16:20 +0100 Original-Received: from localhost ([::1]:39294 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFWPj-00060T-Qt for geh-help-gnu-emacs@m.gmane.org; Sun, 25 Jan 2015 18:16:19 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36754) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFWPX-00060K-KK for help-gnu-emacs@gnu.org; Sun, 25 Jan 2015 18:16:08 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YFWPS-0000vm-KW for help-gnu-emacs@gnu.org; Sun, 25 Jan 2015 18:16:07 -0500 Original-Received: from msg.wmi.amu.edu.pl ([2001:808:114:2::50]:36495) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YFWPS-0000ve-D0 for help-gnu-emacs@gnu.org; Sun, 25 Jan 2015 18:16:02 -0500 Original-Received: from localhost (localhost [127.0.0.1]) by msg.wmi.amu.edu.pl (Postfix) with ESMTP id 43F9A4AC58; Mon, 26 Jan 2015 00:16:00 +0100 (CET) Original-Received: from msg.wmi.amu.edu.pl ([127.0.0.1]) by localhost (msg.wmi.amu.edu.pl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id AQfGXte3pbF3; Mon, 26 Jan 2015 00:16:00 +0100 (CET) Original-Received: from localhost (117-116.echostar.pl [213.156.117.116]) by msg.wmi.amu.edu.pl (Postfix) with ESMTPSA id B7CCE4AC4F; Mon, 26 Jan 2015 00:15:59 +0100 (CET) In-reply-to: <54C5748E.4060605@gmail.com> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:808:114:2::50 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:102264 Archived-At: On 2015-01-25, at 23:56, Will Monroe wrote: > On 01/25/2015 04:45 PM, Drew Adams wrote: >> >> The command `scroll-up' is indeed older, and it is still usable. >> It is, in fact, the core of the `scroll-up-command' implementation. > > Interesting. Given what the author's assumptions of how 'scroll-up' > should work and how the newer 'scroll-up-command' seems to share some, > but not all, of that functionality, it would probably be interesting to > see where they differ. I may not be expressing this clearly, but you've > helped to clarify the question I want to answer to be: "why did > scroll-up-command work where the still useful but not appropriate > scroll-up did not?" That's why it's useful to say M-x find-function RET scroll-up-command RET! >>> I've hesitated from diving into Edebug because there was no >>> "error" as such. That is, the code "worked" it just didn't do >>> what I intended. >> >> Using the debugger (and debugging generally) is not necessarily >> about finding why Emacs raises a particular error. (That is the >> particular use of variable `debug-on-error': enter the debugger >> to show a backtrace when an error is raised.) >> >> In addition to Edebug, there is the regular Emacs debugger, aka >> `debug'. Some of us prefer to use that. Others prefer to use >> it in some cases but `edebug' in other cases. Thanks, Drew, for mentioning that! >> Keep in mind too that any debugger does not necessarily tell you >> everything that goes on, and its representation of what happens >> with debugging turned off is not flawless. In particular, this >> is because using the debugger itself changes what Emacs does. >> (Think of the debugger's buffer display and its handling of >> input events, for example.) >> >> The regular debugger is what you get with `debug-on-entry' and >> by inserting calls to `(debug)' in code to serve more or less as >> breakpoints. See `C-h f debug' for information about evaluating >> and displaying the results of sexps (cdr ARGS) upon entry into >> the debugger. I do not like the (debug) approach, since it seems to be less newbie-friendly. It is true, of course, that Edebug does not always work as intended. > This is very helpful stuff to consider as I begin to think about what I > want to accomplish when using Edebug or debugger. > > And if I'm being honest about why I did not go to Edebug it's because I > was anticipating great difficulty reading the backtrace statements. I > thought my problem might be compounded by a more general illiteracy in > that regard... Now I'm starting to think that it would be nice to study the backtraces once and for all and write about them (for myself and for others)... > Thanks again, Drew. A really helpful answer! Me too! > Will Best, -- Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Faculty of Mathematics and Computer Science Adam Mickiewicz University