From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.devel Subject: comint doesn't like read-only prompts Date: Thu, 13 Jun 2002 10:35:41 +0200 Sender: emacs-devel-admin@gnu.org Message-ID: <20020613103231.CD52.LEKTU@terra.es> NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Trace: main.gmane.org 1023957388 21887 127.0.0.1 (13 Jun 2002 08:36:28 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Thu, 13 Jun 2002 08:36:28 +0000 (UTC) Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 17IQ5k-0005gu-00 for ; Thu, 13 Jun 2002 10:36:28 +0200 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 17IQTw-0007MG-00 for ; Thu, 13 Jun 2002 11:01:28 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 17IQ5Q-0001i4-00; Thu, 13 Jun 2002 04:36:08 -0400 Original-Received: from [62.22.27.141] (helo=mail.peoplecall.com) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 17IQ51-0001h9-00 for ; Thu, 13 Jun 2002 04:35:43 -0400 Original-Received: from jbarranquero (jbarranquero.ofi.peoplecall.com [62.22.27.143]) by mail.peoplecall.com (8.11.6/8.11.6) with ESMTP id g5D8ZfU03167 for ; Thu, 13 Jun 2002 10:35:41 +0200 Original-To: emacs-devel@gnu.org X-Mailer: Becky! ver. 2.00.11 Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.9 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.devel:4819 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:4819 This patch to HEAD is needed to make ielm work again. The problem is that the new handling of text-properties/attributes in comint.el is choking while dealing with ielm's read-only prompt. I've not installed the patch, so people more knowledgeable than me about comint can take a look at it or suggest a better approach. /L/e/k/t/u Index: comint.el =================================================================== RCS file: /cvs/emacs/lisp/comint.el,v retrieving revision 1.273 diff -u -2 -r1.273 comint.el --- comint.el 12 Jun 2002 09:16:51 -0000 1.273 +++ comint.el 13 Jun 2002 08:32:17 -0000 @@ -1538,7 +1538,8 @@ (defun comint-snapshot-last-prompt () (when comint-last-prompt-overlay - (add-text-properties (overlay-start comint-last-prompt-overlay) - (overlay-end comint-last-prompt-overlay) - (overlay-properties comint-last-prompt-overlay)))) + (let ((inhibit-read-only t)) + (add-text-properties (overlay-start comint-last-prompt-overlay) + (overlay-end comint-last-prompt-overlay) + (overlay-properties comint-last-prompt-overlay))))) (defun comint-carriage-motion (string) @@ -1664,8 +1665,9 @@ (unless comint-use-prompt-regexp-instead-of-fields - (add-text-properties comint-last-output-start (point) - '(rear-nonsticky t - field output - inhibit-line-move-field-capture t))) + (let ((inhibit-read-only t)) + (add-text-properties comint-last-output-start (point) + '(rear-nonsticky t + field output + inhibit-line-move-field-capture t)))) ;; Highlight the prompt, where we define `prompt' to mean