From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#16882: 24.3.50; with-temp-buffer-window broken Date: Fri, 28 Feb 2014 11:59:24 +0100 Message-ID: <53106C0C.6070402@gmx.at> References: <87k3cj2fzq.fsf@gmail.com> <6ubnxvj9v4.fsf@fencepost.gnu.org> <8738j7ger3.fsf@gmail.com> <530DBF1E.3090106@gmx.at> <87a9dbaek3.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1393585236 25537 80.91.229.3 (28 Feb 2014 11:00:36 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 28 Feb 2014 11:00:36 +0000 (UTC) Cc: 16882@debbugs.gnu.org To: Thierry Volpiatto Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Feb 28 12:00:41 2014 Return-path: Envelope-to: geb-bug-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 1WJLBI-0004z0-35 for geb-bug-gnu-emacs@m.gmane.org; Fri, 28 Feb 2014 12:00:40 +0100 Original-Received: from localhost ([::1]:50413 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WJLBH-00044g-OB for geb-bug-gnu-emacs@m.gmane.org; Fri, 28 Feb 2014 06:00:39 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40589) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WJLAu-0003c5-8r for bug-gnu-emacs@gnu.org; Fri, 28 Feb 2014 06:00:23 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WJLAm-0008Ou-SL for bug-gnu-emacs@gnu.org; Fri, 28 Feb 2014 06:00:16 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:42470) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WJLAm-0008OW-PL for bug-gnu-emacs@gnu.org; Fri, 28 Feb 2014 06:00:08 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1WJLAm-00014v-2l for bug-gnu-emacs@gnu.org; Fri, 28 Feb 2014 06:00:08 -0500 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 28 Feb 2014 11:00:07 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 16882 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 16882-submit@debbugs.gnu.org id=B16882.13935851683958 (code B ref 16882); Fri, 28 Feb 2014 11:00:07 +0000 Original-Received: (at 16882) by debbugs.gnu.org; 28 Feb 2014 10:59:28 +0000 Original-Received: from localhost ([127.0.0.1]:43646 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WJLA7-00011l-Gt for submit@debbugs.gnu.org; Fri, 28 Feb 2014 05:59:27 -0500 Original-Received: from mout.gmx.net ([212.227.17.20]:53827) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WJLA6-00011e-EW for 16882@debbugs.gnu.org; Fri, 28 Feb 2014 05:59:26 -0500 Original-Received: from [62.47.57.2] ([62.47.57.2]) by mail.gmx.com (mrgmx102) with ESMTPSA (Nemesis) id 0MfjJY-1WXaGH1iB2-00NCNZ for <16882@debbugs.gnu.org>; Fri, 28 Feb 2014 11:59:25 +0100 In-Reply-To: <87a9dbaek3.fsf@gmail.com> X-Provags-ID: V03:K0:EG9EoC92ijvIUnzkLPA6hYgh/8nW1LIY//akv8PVnboE0bSP6Lh i3tPeTHxNaAYQl0BkR5l/Gju8uP3x0CWGv4GGEd/mOT5zwKys4NNwiUrW7Wht+uT59ZV9UY bAtB82JUijDsaO8X0LnBRUOYKnUhqS5PJ64mcCD4kAY5l+9+1OY6IslKBbPwdf9kMDgUxfo kjBx+Fwo4TQ1j5JPnmT0w== X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x 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:86370 Archived-At: > Just a note on this: (Sorry to insist) > > You expect here the code of 'body' returns a stream like prin* function > family does, but IMHO 'body' should be any code that is self > contained in the "temp-buffer-window" and not elsewhere. > IOW the actual version is not safe in this sens because it may affect > the current-buffer. > I suspect already existing code is affected by this new behavior. > > Try: > > (with-temp-buffer-window "foo" nil nil (princ "hello")) > > and now > > (with-temp-buffer-window "foo" nil nil (insert "hello")) > > I expect here "hello" to be inserted in "foo" buffer, but actually it > corrupt current-buffer. As the bug found by Juanma shows I was fooled by this myself. It should now behave again in your sense. I still have to explain the behavior in the manual. Thanks, martin