From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#74276: 30.0.90; undo does not account for overlays now that markers are not used Date: Sat, 09 Nov 2024 10:12:53 +0200 Message-ID: <86fro0omey.fsf@gnu.org> References: <86jzdcsyc1.fsf@gmx.net> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33321"; mail-complaints-to="usenet@ciao.gmane.io" Cc: karthikchikmagalur@gmail.com, 74276@debbugs.gnu.org To: James Thomas , Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Nov 09 09:14:20 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1t9gbr-0008Y9-95 for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 09 Nov 2024 09:14:19 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t9gbd-0002lT-Ek; Sat, 09 Nov 2024 03:14:05 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t9gbb-0002lI-13 for bug-gnu-emacs@gnu.org; Sat, 09 Nov 2024 03:14:03 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t9gba-0002iZ-PE for bug-gnu-emacs@gnu.org; Sat, 09 Nov 2024 03:14:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=References:In-Reply-To:From:Date:To:Subject; bh=dWfTItxOBgG3n9BMfpulPoc2taL2OU3djjzR4JE27DQ=; b=PeqBiszMtUUNEVAsUBAOVesDeOz5cufGs3Ue1/WUCmweXtnlVxgyW7xKmQjZpLbiOurH3rLcAsTOP5aONExv2Ng/BrXrNQLOEBO4wAbzQYjojR+1JluwVxCnmCbxfGGas3OkguHymb1kHz3qVHtWjYM/SJ9Mxef66Iv+MJlQZ+AZVCDR/yrJPPkYSPuzo7Ip4nr+l6WlRYY7QPeU4oFp2S2/3YMIfcJd2613qgM1ut5n8j85IjBag4reWGcAE/NSQ5lhQ/jy2slzdp2X9Ny1B6+BQs4Hfl073g17kG4RE8ruGCBBSzWLPJwZGN1ExswTcEqjihfNE3UTNFHUL2L9Dw==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t9gbZ-0007A4-Lg for bug-gnu-emacs@gnu.org; Sat, 09 Nov 2024 03:14:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 09 Nov 2024 08:14:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74276 X-GNU-PR-Package: emacs Original-Received: via spool by 74276-submit@debbugs.gnu.org id=B74276.173113998927457 (code B ref 74276); Sat, 09 Nov 2024 08:14:01 +0000 Original-Received: (at 74276) by debbugs.gnu.org; 9 Nov 2024 08:13:09 +0000 Original-Received: from localhost ([127.0.0.1]:53267 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t9gaj-00078n-5B for submit@debbugs.gnu.org; Sat, 09 Nov 2024 03:13:09 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:33056) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t9gag-00078J-Cv for 74276@debbugs.gnu.org; Sat, 09 Nov 2024 03:13:07 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t9gaX-0002gj-BH; Sat, 09 Nov 2024 03:12:59 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=dWfTItxOBgG3n9BMfpulPoc2taL2OU3djjzR4JE27DQ=; b=SUNP2ohOcAcV hz7Jev/QiSNh5gJsTAN3fmYZ5bUl0tmQf3ikLiyh5/b5YLgFGT8JfxO1fMMlf5SowMONiixwbEPoi O1wKgNKMRQrBBenf3f2PRrjfX7LFkeHkZBvazB+qmQpSnxhKPVwGQdlZDkkopEO9YSunM8GmKZ8Jr 1muxlBCHCfbGSEc4wJY/w1CkcKVoXsmggZ7x1qD5uNVwHUbj/efn9FR5JkZKXqeZJTyYeRlm5SKDO 4yhYSGKAOv6svN/n9I+W+Sn4aYqkaNhLED80sMm08RtGCIiq0UFSiNz5wPXsdJPdx7FS6QEZYktTl 9JWQxxzsgRpCj+cwNX7V2w==; In-Reply-To: <86jzdcsyc1.fsf@gmx.net> (bug-gnu-emacs@gnu.org) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:295097 Archived-At: > Cc: karthikchikmagalur@gmail.com > Date: Sat, 09 Nov 2024 12:11:50 +0530 > From: James Thomas via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > - emacs -Q > - Type: abcdef > - C-a > - M-: (overlay-put (make-overlay (point) (+ (point) 3)) 'face 'highlight) > - Mark the text 'bcd' and delete it > - M-x undo (does not restore overlay correctly) > > (The solution seems to me to be for undo to also store the overlay, > adjustment, and whether left, right or both boundaries are involved, and > use it) This didn't work with the old implementation of overlays, either. I just tested in Emacs 25 and I see the same results there. Stefan, does undo restore overlays, and if so, how? I don't see anything pertinent in the Undo section of the ELisp manual except the reference to markers (which overlays don't have anymore). Did that ever work, and if so, how? And how should it work now?