From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Ilya N. Golubev" Newsgroups: gmane.emacs.xemacs.beta,gmane.emacs.bugs Subject: field movement fix [Re: comint loses prompt boundary] Date: Tue, 12 Dec 2006 21:08:34 +0300 Message-ID: <82odq9aswt.fsf@mo.msk.ru> References: <16k64g20tu.fsf@mo.msk.ru> <59ejumjzz2.fsf@mo.msk.ru> <843bazvd1b.fsf@mo.msk.ru> <87slflasys.fsf@mo.msk.ru> NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1165948096 10132 80.91.229.10 (12 Dec 2006 18:28:16 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 12 Dec 2006 18:28:16 +0000 (UTC) Cc: Jerry James , xemacs-beta@xemacs.org Original-X-From: xemacs-beta-bounces@xemacs.org Tue Dec 12 19:28:13 2006 Return-path: Envelope-to: gexb-xemacs-beta-2@gmane.org Original-Received: from 98.f7bed1.client.atlantech.net ([209.190.247.152] helo=calypso.tux.org) by dough.gmane.org with esmtp (Exim 4.50) id 1GuCMK-0000dA-Cm for gexb-xemacs-beta-2@gmane.org; Tue, 12 Dec 2006 19:28:08 +0100 Original-Received: from calypso.tux.org (localhost [127.0.0.1]) by calypso.tux.org (Postfix) with ESMTP id CDB3C1178F4; Tue, 12 Dec 2006 13:28:03 -0500 (EST) Original-Received: from gwyn.tux.org (gwyn.tux.org [207.172.156.132]) by calypso.tux.org (Postfix) with ESMTP id D009D1178A9 for ; Tue, 12 Dec 2006 13:28:01 -0500 (EST) Original-Received: from gwyn.tux.org (ident-user@localhost.localdomain [127.0.0.1]) by gwyn.tux.org (8.12.11/8.12.11) with ESMTP id kBCIS1Eu029556 for ; Tue, 12 Dec 2006 13:28:01 -0500 Original-Received: (from xemacweb@localhost) by gwyn.tux.org (8.12.11/8.12.11/Submit) id kBCIS1bU029555 for xemacs-beta@calypso.tux.org; Tue, 12 Dec 2006 13:28:01 -0500 Original-Received: from gwyn.tux.org (ident-user@localhost.localdomain [127.0.0.1]) by gwyn.tux.org (8.12.11/8.12.11) with ESMTP id kBCIRw3b029512 for ; Tue, 12 Dec 2006 13:27:58 -0500 Original-Received: (from mailnull@localhost) by gwyn.tux.org (8.12.11/8.12.11/Submit) id kBCIRwXO029511 for xemacweb@tux.org; Tue, 12 Dec 2006 13:27:58 -0500 Original-Received: from yxa.extundo.com (178.230.13.217.in-addr.dgcsystems.net [217.13.230.178]) by gwyn.tux.org (8.12.11/8.12.11) with ESMTP id kBCIQunS028931; Tue, 12 Dec 2006 13:27:57 -0500 Original-Received: from d-fens.mopniei.ru (mx.mo.msk.ru [62.213.85.9]) by yxa.extundo.com (8.13.4/8.13.4/Debian-3sarge3) with ESMTP id kBCI8mSG023881 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 12 Dec 2006 19:09:13 +0100 Original-Received: from d-fens.mopniei.ru (localhost.localdomain [127.0.0.1]) by d-fens.mopniei.ru (8.13.7/8.13.7) with ESMTP id kBCI8ZBF010492 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 12 Dec 2006 21:08:35 +0300 Original-Received: (from gin@localhost) by d-fens.mopniei.ru (8.13.7/8.13.7/Submit) id kBCI8YXA010491; Tue, 12 Dec 2006 21:08:34 +0300 X-Authentication-Warning: d-fens.mopniei.ru: gin set sender to gin@mo.msk.ru using -f Original-To: bug-gnu-emacs@gnu.org X-Spam-Status: No, score=-0.8 required=4.0 tests=AWL,BAYES_50, FORGED_RCVD_HELO autolearn=ham version=3.1.1 X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on yxa-iv X-Virus-Scanned: ClamAV version 0.88.4, clamav-milter version 0.88.4 on gwyn.tux.org X-Virus-Scanned: ClamAV version 0.88.4, clamav-milter version 0.88.4 on gwyn.tux.org X-Virus-Scanned: ClamAV version 0.88.4, clamav-milter version 0.88.4 on gwyn.tux.org X-Virus-Scanned: ClamAV version 0.88.2, clamav-milter version 0.88.2 on yxa.extundo.com X-Virus-Status: Clean X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-1.6 (gwyn.tux.org [0.0.0.0]); Tue, 12 Dec 2006 13:28:01 -0500 (EST) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-1.6 (gwyn.tux.org [0.0.0.0]); Tue, 12 Dec 2006 13:27:58 -0500 (EST) X-Greylist: Delayed for 00:18:35 by milter-greylist-1.6 (gwyn.tux.org [207.172.156.133]); Tue, 12 Dec 2006 13:27:57 -0500 (EST) X-XEmacs-List: beta X-BeenThere: xemacs-beta@xemacs.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports and discussion of XEmacs development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: xemacs-beta-bounces@xemacs.org Errors-To: xemacs-beta-bounces@xemacs.org Xref: news.gmane.org gmane.emacs.xemacs.beta:23843 gmane.emacs.bugs:15450 Archived-At: Fixing what described on Thu, 07 Sep 2006 00:32:13 +0400 in <16k64g20tu.fsf@mo.msk.ru> () in emacs cvs head (as of 2006-11-23) as follows. This also makes comint, shell conform to documentation as suggested in <87slflasys.fsf@mo.msk.ru>. Cc-ing to Jerry James, since the broken code from emacs was merged into xemacs packages `comint.el' revision 1.14 of 2006/05/25 02:49:47 +0, and they were among recipients of the original report. lisp/ChangeLog * comint.el (comint-line-beginning-position): Fix undocumented dependency on `inhibit-field-text-motion' value: do the same regardless of how this user option is set. etc/ChangeLog * NEWS (Fixed to respects fields): New. (Comint changes): In here. --- lisp/comint.el 2006-11-23 15:55:54.000000000 +0300 +++ lisp/comint.el 2006-12-07 02:53:38.794286184 +0300 @@ -1953,7 +1953,8 @@ ;; if there are two fields on a line, then the first one is the ;; prompt, and the second one is an input field, and is front-sticky ;; (as input fields should be). - (constrain-to-field (line-beginning-position) (line-end-position)))) + (let ((inhibit-field-text-motion nil)) + (constrain-to-field (line-beginning-position) (line-end-position))))) (defun comint-bol (&optional arg) "Go to the beginning of line, then skip past the prompt, if any. --- etc/NEWS 2006-11-23 15:55:51.000000000 +0300 +++ etc/NEWS 2006-12-07 05:10:21.731250216 +0300 @@ -21,6 +21,39 @@ so we will look at it and add it to the manual. +* Incompatible Editing Changes in local gin branch. + +** Fixed comint commands to respect fields. + +As described in section. This includes, but not limited to `comint-bol', +`comint-insert-previous-argument', `comint-backward-matching-input', +`comint-bol-or-process-mark', `comint-previous-matching-input', +`comint-send-input', `comint-copy-old-input', +`shell-backward-command', `shell-dynamic-complete-command' (including +inside `comint-dynamic-complete' in Shell mode). + + +* Incompatible Lisp Changes in local gin branch. + +** Fixed `comint-line-beginning-position' to respect fields. + +As controlled by `inhibit-field-text-motion'. This fixed myriads of +other functions and commands that depend on it and that rely on it to +always do so, regardless of `inhibit-field-text-motion' user option, +at least when `comint-use-prompt-regexp' is `nil'. Partial list of +these commands is in +section. However, other code certainly may rely on old behavior. +Have not seen such a code to date. + +Introduced in upstream just after addition of (extant) field +implementation of 2000-01-01. + +Other non- interactive functions calling it include +`comint-replace-by-expanded-history-before-point', +`comint-get-old-input-default'. + + * Installation Changes in Emacs 22.1 --- @@ -1461,6 +1494,37 @@ that need to know whether they are started inside Emacs should check INSIDE_EMACS instead of EMACS. +*** Fixed to respects fields. + +As controlled by `inhibit-field-text-motion'. As bug fix, certainly +incompatible with buggy behavior. + +**** Lisp changes. + +The core change is in `comint-line-beginning-position'. This fixed +myriads of other functions and commands that depend on it and that +rely on it to always do so, regardless of `inhibit-field-text-motion' +user option, at least when `comint-use-prompt-regexp' is `nil'. +Partial list of these commands is in section. +However, other code certainly may rely on old behavior. Have not seen +such a code to date. + +Introduced in upstream emacs just after addition of (extant) field +implementation of 2000-01-01. + +Other non- interactive functions calling it include +`comint-replace-by-expanded-history-before-point', +`comint-get-old-input-default'. + +**** Editing changes. + +Include, but not limited to `comint-bol', +`comint-insert-previous-argument', `comint-backward-matching-input', +`comint-bol-or-process-mark', `comint-previous-matching-input', +`comint-send-input', `comint-copy-old-input', +`shell-backward-command', `shell-dynamic-complete-command' (including +inside `comint-dynamic-complete' in Shell mode). + ** M-x Compile changes: ---