From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: storm@cua.dk (Kim F. Storm) Newsgroups: gmane.emacs.devel Subject: Re: Ok, here is the bug I have been looking for. Kim, not Jan... Date: Tue, 01 Mar 2005 09:34:37 +0100 Message-ID: References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1109667076 28977 80.91.229.2 (1 Mar 2005 08:51:16 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 1 Mar 2005 08:51:16 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Mar 01 09:51:15 2005 Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1D634f-0006n4-NC for ged-emacs-devel@m.gmane.org; Tue, 01 Mar 2005 09:49:50 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1D63NB-0004P9-O7 for ged-emacs-devel@m.gmane.org; Tue, 01 Mar 2005 04:08:57 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1D63Eg-0008Mt-QQ for emacs-devel@gnu.org; Tue, 01 Mar 2005 04:00:10 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1D63Ea-0008Jt-1n for emacs-devel@gnu.org; Tue, 01 Mar 2005 04:00:05 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1D63EZ-00088c-86 for emacs-devel@gnu.org; Tue, 01 Mar 2005 04:00:03 -0500 Original-Received: from [212.88.64.25] (helo=mail-relay.sonofon.dk) by monty-python.gnu.org with smtp (Exim 4.34) id 1D62wM-00055H-KU for emacs-devel@gnu.org; Tue, 01 Mar 2005 03:41:14 -0500 Original-Received: (qmail 50105 invoked from network); 1 Mar 2005 08:34:32 -0000 Original-Received: from unknown (HELO kfs-l.imdomain.dk.cua.dk) (213.83.150.2) by 0 with SMTP; 1 Mar 2005 08:34:32 -0000 Original-To: David Kastrup In-Reply-To: (David Kastrup's message of "Tue, 01 Mar 2005 05:58:43 +0100") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org X-MailScanner-To: ged-emacs-devel@m.gmane.org Xref: main.gmane.org gmane.emacs.devel:33966 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:33966 David Kastrup writes: > With -fno-crossjumping, the real assert came to light. > > It is xdisp.c in line 6122: > > /* The function move_it_vertically_backward may move over more > than the specified y-distance. If it->w is small, e.g. a > mini-buffer window, we may end up in front of the window's > display area. Start displaying at the start of the line > containing PT in this case. */ > if (it.current_y <= 0) > { > init_iterator (&it, w, PT, PT_BYTE, NULL, DEFAULT_FACE_ID); > move_it_vertically_backward (&it, 0); > xassert (IT_CHARPOS (it) <= PT); > it.current_y = 0; > } > > I suppose that the reseat_1 in move_it_vertically_backward will move > forward again. Something like that. True. This can happen if PT is invisible text or in text that is replaced by an image. I guess it is related to a bug that I still have to investigate (see below). I think you can safely disable the xassert with #if 0 for now. The bug reveals itself like this: Suppose you have a window with this context abc [ ] [IMAGE]xyz [ ] def Now, if you place the cursor at 'z' and hit C-a, it moves to 'x'. Also, M-: (bolp) returns t at that position. I haven't fully debugged this, but it seems to happen when the text overlayed by the IMAGE includes or ends with a newline. -- Kim F. Storm http://www.cua.dk