From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.bugs Subject: bug#10122: 24.0.91; C-x C-v, invisible text: "Cannot switch...dedicated window" Date: Wed, 23 Nov 2011 15:33:27 -0800 Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1322091294 30245 80.91.229.12 (23 Nov 2011 23:34:54 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 23 Nov 2011 23:34:54 +0000 (UTC) To: 10122@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Nov 24 00:34:51 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RTML4-0003sg-8m for geb-bug-gnu-emacs@m.gmane.org; Thu, 24 Nov 2011 00:34:50 +0100 Original-Received: from localhost ([::1]:45415 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RTML3-0008C7-Rr for geb-bug-gnu-emacs@m.gmane.org; Wed, 23 Nov 2011 18:34:49 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:35397) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RTMKx-0008C2-R2 for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2011 18:34:48 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RTMKo-00067M-QF for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2011 18:34:43 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:34813) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RTMKo-00067I-NV for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2011 18:34:34 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RTMME-0002UE-BF for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2011 18:36:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: "Drew Adams" Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 23 Nov 2011 23:36:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 10122 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: Original-Received: via spool by submit@debbugs.gnu.org id=B.13220913209500 (code B ref -1); Wed, 23 Nov 2011 23:36:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 23 Nov 2011 23:35:20 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RTMLY-0002TB-Ac for submit@debbugs.gnu.org; Wed, 23 Nov 2011 18:35:20 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RTMLW-0002T4-0N for submit@debbugs.gnu.org; Wed, 23 Nov 2011 18:35:18 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RTMK2-00064V-4M for submit@debbugs.gnu.org; Wed, 23 Nov 2011 18:33:49 -0500 Original-Received: from lists.gnu.org ([140.186.70.17]:36179) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RTMK2-00064R-2r for submit@debbugs.gnu.org; Wed, 23 Nov 2011 18:33:46 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:44008) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RTMJw-0007wt-2k for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2011 18:33:45 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RTMJq-0005wl-5y for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2011 18:33:40 -0500 Original-Received: from rcsinet15.oracle.com ([148.87.113.117]:53385) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RTMJq-0005wf-0m for bug-gnu-emacs@gnu.org; Wed, 23 Nov 2011 18:33:34 -0500 Original-Received: from ucsinet21.oracle.com (ucsinet21.oracle.com [156.151.31.93]) by rcsinet15.oracle.com (Switch-3.4.4/Switch-3.4.4) with ESMTP id pANNXW8B011213 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 23 Nov 2011 23:33:32 GMT Original-Received: from acsmt358.oracle.com (acsmt358.oracle.com [141.146.40.158]) by ucsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id pANNXVdc012302 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Wed, 23 Nov 2011 23:33:31 GMT Original-Received: from abhmt110.oracle.com (abhmt110.oracle.com [141.146.116.62]) by acsmt358.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id pANNXQsP000974 for ; Wed, 23 Nov 2011 17:33:26 -0600 Original-Received: from dradamslap1 (/10.159.44.3) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 23 Nov 2011 15:33:25 -0800 X-Mailer: Microsoft Office Outlook 11 Thread-Index: AcyqOEzzrZrBo0tbQJG4yK8VDu5EGw== X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet21.oracle.com [156.151.31.93] X-CT-RefId: str=0001.0A090209.4ECD82CD.000A,ss=1,re=0.594,fgs=0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 1) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Wed, 23 Nov 2011 18:36:02 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:54239 Archived-At: This is with my setup. I don't have a recipe from emacs -Q. Among other things, buffers that have names `*...*' are special-display, and I have non-nil `pop-up-frames'. In a small elisp file buffer, I make a couple of contiguous definitions invisible, using (put-text-property (region-beginning) (region-end) 'invisible t). Then I do `C-x C-v' and accept the default, which is the same file. I enter `no' to the question about saving modified buffer, and `yes' to the question about killing and replacing without saving. Buffer *Pp Eval Ouput* pops up (in a separate frame), with value `nil' displayed. Just after it pops up, buffer *Backtrace* pops up, with this: Debugger entered--Lisp error: (error "Buffer name `throw-test.el' is in use") rename-buffer("throw-test.el") byte-code("..." [obuf ofile buffer-file-name onum buffer-file-number otrue lock-buffer rename-buffer buffer-file-truename odir dired-directory oname] 2) signal(error ("Cannot switch buffers in a dedicated window")) error("Cannot switch buffers in a dedicated window") old-switch-to-buffer(# nil force-same-window) switch-to-buffer(# nil force-same-window) find-file("c:/drews-lisp-20/throw-test.el" t) find-alternate-file("c:/drews-lisp-20/throw-test.el" t) call-interactively(find-alternate-file nil nil) Also, buffer `**lose**' has taken the place of the original elisp file buffer in the same (undedicated) window. The content of buffer `**lose**' is the elisp buffer content, with the hidden sexps still invisible. The original lisp buffer still exists, but is not displayed. If I display it I see the whole buffer - nothing is invisible. It seems like maybe: (a) something causes an evaluation, which shows *Pp Eval Output* (even for the small value `nil' - no idea why) (b) perhaps *Pp Eval Output* becomes the current buffer (?) (c) since it is in a dedicated window, Emacs barfs, saying it is unable to show the orginal file in that same window. I do not see the same problem if there is no invisible text. Buffer *Messages* shows nothing particular. I have no idea what evaluation led to *Pp Eval Output* being shown, nor why it would be shown for as simple a value as nil. Note that the elisp file buffer was NEVER shown in a dedicated window. There were NO dedicated windows when I used `C-x C-v'. The first dedicated window shown was *Pp Eval Output*, and the second was *Backtrace*. There were no other dedicated windows. This is the (re)definition of `switch-to-buffer' that I use: (defun switch-to-buffer (buffer-or-name &optional norecord force-same-window) "..." (interactive (list (read-buffer-to-switch "Switch to buffer: ") nil 'force-same-window)) (let ((orig-buf (current-buffer)) (switch-buf (old-switch-to-buffer buffer-or-name norecord force-same-window))) (when (and (one-window-p t) (not (eq switch-buf orig-buf)) ; Don't resize if same buffer. autofit-frames-flag (fit-frame))) switch-buf)) where `old-switch-to-buffer' was defined this way: (fset 'old-switch-to-buffer (symbol-function 'switch-to-buffer)) This is 100% reproducible, but as I say, this is with my setup. Perhaps you have enough info to figure the problem out? In GNU Emacs 24.0.91.1 (i386-mingw-nt5.1.2600) of 2011-11-21 on MARVIN Windowing system distributor `Microsoft Corp.', version 5.1.2600 configured using `configure --with-gcc (4.6) --no-opt --cflags -ID:/devel/emacs/libs/libXpm-3.5.8/include -ID:/devel/emacs/libs/libXpm-3.5.8/src -ID:/devel/emacs/libs/libpng-dev_1.4.3-1/include -ID:/devel/emacs/libs/zlib-dev_1.2.5-2/include -ID:/devel/emacs/libs/giflib-4.1.4-1/include -ID:/devel/emacs/libs/jpeg-6b-4/include -ID:/devel/emacs/libs/tiff-3.8.2-1/include -ID:/devel/emacs/libs/gnutls-2.10.1/include --ldflags -LD:/devel/emacs/libs/gnutls-2.10.1/lib'