From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#23785: Emacs 25: "Undo" overdoes things. Date: Fri, 17 Jun 2016 15:02:45 +0000 Message-ID: <20160617150245.GB3316@acm.fritz.box> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="G4iJoqBmSsgzjUCe" Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1466177697 6514 80.91.229.3 (17 Jun 2016 15:34:57 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 17 Jun 2016 15:34:57 +0000 (UTC) To: 23785@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Jun 17 17:34:43 2016 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 1bDvn6-0007iy-Ni for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Jun 2016 17:34:41 +0200 Original-Received: from localhost ([::1]:58402 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDvn6-0002Zd-0p for geb-bug-gnu-emacs@m.gmane.org; Fri, 17 Jun 2016 11:34:40 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60770) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDvIY-0002kI-9u for bug-gnu-emacs@gnu.org; Fri, 17 Jun 2016 11:03:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bDvIU-0004BO-3x for bug-gnu-emacs@gnu.org; Fri, 17 Jun 2016 11:03:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:60299) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDvIU-0004BJ-1n for bug-gnu-emacs@gnu.org; Fri, 17 Jun 2016 11:03:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bDvIT-0007bT-Pd for bug-gnu-emacs@gnu.org; Fri, 17 Jun 2016 11:03:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 17 Jun 2016 15:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 23785 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.146617576829206 (code B ref -1); Fri, 17 Jun 2016 15:03:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 17 Jun 2016 15:02:48 +0000 Original-Received: from localhost ([127.0.0.1]:44403 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bDvIF-0007az-PA for submit@debbugs.gnu.org; Fri, 17 Jun 2016 11:02:47 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:41309) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bDvID-0007an-IS for submit@debbugs.gnu.org; Fri, 17 Jun 2016 11:02:46 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bDvI7-0003zk-C9 for submit@debbugs.gnu.org; Fri, 17 Jun 2016 11:02:40 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:39394) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDvI7-0003zf-9O for submit@debbugs.gnu.org; Fri, 17 Jun 2016 11:02:39 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60418) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDvI5-0002HS-CB for bug-gnu-emacs@gnu.org; Fri, 17 Jun 2016 11:02:38 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bDvI0-0003vl-Jm for bug-gnu-emacs@gnu.org; Fri, 17 Jun 2016 11:02:36 -0400 Original-Received: from mail.muc.de ([193.149.48.3]:40029) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDvI0-0003uG-9E for bug-gnu-emacs@gnu.org; Fri, 17 Jun 2016 11:02:32 -0400 Original-Received: (qmail 86867 invoked by uid 3782); 17 Jun 2016 15:02:30 -0000 Original-Received: from acm.muc.de (p548C685D.dip0.t-ipconnect.de [84.140.104.93]) by colin.muc.de (tmda-ofmipd) with ESMTP; Fri, 17 Jun 2016 17:02:29 +0200 Original-Received: (qmail 6855 invoked by uid 1000); 17 Jun 2016 15:02:45 -0000 Content-Disposition: inline User-Agent: Mutt/1.5.24 (2015-08-30) X-Delivery-Agent: TMDA/1.1.12 (Macallan) X-Primary-Address: acm@muc.de X-detected-operating-system: by eggs.gnu.org: FreeBSD 9.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:119671 Archived-At: --G4iJoqBmSsgzjUCe Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit Hello, Emacs. Summary: `undo' is broken in Emacs 25. In GNU Emacs 25.0.94.2 (x86_64-unknown-linux-gnu, GTK+ Version 3.18.7) of 2016-06-07 built on acm Repository revision: 9d5ccebeba0506f7280662630f0ee85a52c8a327 Configured using: 'configure --with-tiff=no --with-gif=no --with-gpm' 1. emacs -Q 2. C-x C-f decls-6.cc ; file is attached. 3. Move point to BOL 17. 4. C-o, and insert the line "Type var = init;". Call this line 16½. 5. M-x revert-buffer. 6. Move point to "[" on L16, and use C-M-k to delete "[3 * peq]". 7. C-_. This restores "[3 * peq]" (correctly) but also reinserts line 16½ (which is a bug). [For reference, the pertinent part of the file looks like this. In the actual file "Type" is at column zero: 14. Type var = init, x = Type(); 15. Type (*var) = init; 16. Type var[3 * peq] = init; 16½. Type var = init; <======== inserted line. 17. Type (var) = init; 18. Type int = "int"; // int ]. -- Alan Mackenzie (Nuremberg, Germany). --G4iJoqBmSsgzjUCe Content-Type: text/x-c; charset=us-ascii Content-Disposition: attachment; filename="decls-6.cc" __INLINE__ FOO Type var, x; __INLINE__ FOO Type *var; __INLINE__ FOO Type var[3 * peq]; // This is an init paren that currently incorrectly causes the // variable to be recognized as a function. __INLINE__ FOO Type var (peq); __INLINE__ FOO Type var = init, x = Type(); __INLINE__ FOO Type (*var) = init; __INLINE__ FOO Type var[3 * peq] = init; __INLINE__ FOO Type var int = "int"; // int Type var = init, x = Type(); Type (*var) = init; Type var[3 * peq] = init; Type (var) = init; Type int = "int"; // int const Type var; const Type (*var); const Type var[3 * peq]; const Type (var); Type (*foo) (Type *, Type (*)[x], Type (*var)[x], // An incorrect one that gets "var" recorded as a type. Type (var*)[x], Type &); Type2 var; Type var; Type (*var); // Currently treated as function call. Type (*var)[3]; Type var[3 * peq]; Type (var); // Currently treated as function call. Type (var)(); ::Type var; unsigned foo bar; long long x; long double y; int x y; // Invalid int int y; // Invalid // This should be last to check a certain case. #define low_assign_multiset_index(TO, NODE) do { \ struct svalue *_ms_index_to2_ = (TO); \ } while (0) --G4iJoqBmSsgzjUCe--