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#51766: 29.0.50; Return value of buffer-chars-modified-tick changes when buffer text is not yet changed before inserting a character for non-latin input methods Date: Sat, 13 Nov 2021 17:24:49 +0200 Message-ID: <837ddcxem6.fsf@gnu.org> References: <87mtmalrs1.fsf@localhost> <837dde200c.fsf@gnu.org> <87k0helmig.fsf@localhost> <831r3m1tpk.fsf@gnu.org> <8735o1r31q.fsf@localhost> <834k8hzi10.fsf@gnu.org> <87zgq9pmb6.fsf@localhost> <831r3lzfk4.fsf@gnu.org> <87wnldpk5x.fsf@localhost> <83zgq9xv1y.fsf@gnu.org> <87r1bkpgjw.fsf@localhost> <83pmr4xt4c.fsf@gnu.org> <87o86opa3j.fsf@localhost> <83k0hcxjju.fsf@gnu.org> <87sfw0glq2.fsf@localhost> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11329"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 51766@debbugs.gnu.org To: Ihor Radchenko Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Nov 13 16:26:17 2021 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 1mluv2-0002mV-Tw for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 13 Nov 2021 16:26:17 +0100 Original-Received: from localhost ([::1]:54838 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mluv1-0000ML-Nz for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 13 Nov 2021 10:26:15 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:47876) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mluuo-0000JJ-5M for bug-gnu-emacs@gnu.org; Sat, 13 Nov 2021 10:26:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:36352) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mluun-0001qj-TV for bug-gnu-emacs@gnu.org; Sat, 13 Nov 2021 10:26:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mluun-00007y-Nz for bug-gnu-emacs@gnu.org; Sat, 13 Nov 2021 10:26: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, 13 Nov 2021 15:26:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51766 X-GNU-PR-Package: emacs Original-Received: via spool by 51766-submit@debbugs.gnu.org id=B51766.1636817115428 (code B ref 51766); Sat, 13 Nov 2021 15:26:01 +0000 Original-Received: (at 51766) by debbugs.gnu.org; 13 Nov 2021 15:25:15 +0000 Original-Received: from localhost ([127.0.0.1]:47898 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mluu3-00006q-9n for submit@debbugs.gnu.org; Sat, 13 Nov 2021 10:25:15 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:47012) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mluu0-00006X-O1 for 51766@debbugs.gnu.org; Sat, 13 Nov 2021 10:25:14 -0500 Original-Received: from [2001:470:142:3::e] (port=53928 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mluts-0001gO-V7; Sat, 13 Nov 2021 10:25:05 -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=2K6yzyWM33Y2U6+ivOKFo42WAqvn/wLCfDiDVlY+JTo=; b=mx2Si46Wg1q+ tb+GYoCI0cmNy3aQU3UdybxlKbiDifPn4GO6mRTbw5boQybSBJbtxMFtDF0r3kTPGaLZyI5UgbnfY xf7agaCdDB5AYjtitRnu01wUnylcnI412AcufLFcm4gS2IePEsYMeaJkOOI66gPsT89IsMaFOOKs8 Zsv29Kl8yT5fj2VhnKoAy1NRS3p5U4xzvf+kTWYxAo+bJlAQeK8nFGxw8u8ZkMya1anvtrCA0xZDc DXJ+TPCHUqFy4Vo8coKp2laNjKm3UpZkcvvfFDT+wf1GvSPkVBmoPgSZ060XCEsrjkbnzaylEc+GG bDIraUdyejAhxFvLOSElMw==; Original-Received: from [87.69.77.57] (port=1918 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mluts-0003SQ-Fi; Sat, 13 Nov 2021 10:25:04 -0500 In-Reply-To: <87sfw0glq2.fsf@localhost> (message from Ihor Radchenko on Sat, 13 Nov 2021 22:43:17 +0800) 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" Xref: news.gmane.io gmane.emacs.bugs:219818 Archived-At: > From: Ihor Radchenko > Cc: 51766@debbugs.gnu.org > Date: Sat, 13 Nov 2021 22:43:17 +0800 > > > But if buffer-modified-tick completely explains the change in > > buffer-chars-modified-tick, you can conclude that > > buffer-chars-modified-tick didn't change for your purposes, and then > > all's well, no? > > I looked into it again and tried to play with non-cyrillic input looking > at the values of buffer-chars-modified-tick and buffer-modified-tick. > You are right, there seems to be a special relation between the values > when I use non-latin input method > (buffer-chars-modified-tick=buffer-modified-tick). Thanks! That's what the implementation does: it copies the value from the latter to the former. > However, I am not sure if equality of the chars-modified-tick and > modified-tick is unique to non-changing edits. Can test in the wild > though. I'd be surprised if the relation were violated. But weirder things have happened, so... > > Then maybe this is the missing infrastructure you'd like to see > > implemented. > > Yes, I think. In practical terms, it may something like a new pair of > hooks: before/after-change-no-inhibit-functions. The hooks work exactly > like before/after-change-functions, but cannot be suppressed by > let-binding inhibit-modification-hooks and > before/after-change-functions. If necessary they can still be explicitly > let-bound to nil, but it should be discouraged. WDYT? Something like that, yes. Just with shorter names ;-)