From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: master 99c637499e: Only apply last change to the clipboard Date: Tue, 01 Feb 2022 00:20:30 -0500 Message-ID: References: <164368163944.24305.8528536193885928245@vcs2.savannah.gnu.org> <20220201021359.C439EC40717@vcs2.savannah.gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7587"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: Po Lu To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Feb 01 06:22:11 2022 Return-path: Envelope-to: ged-emacs-devel@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 1nElcJ-0001hT-7x for ged-emacs-devel@m.gmane-mx.org; Tue, 01 Feb 2022 06:22:11 +0100 Original-Received: from localhost ([::1]:59594 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nElcH-0005Gy-S6 for ged-emacs-devel@m.gmane-mx.org; Tue, 01 Feb 2022 00:22:09 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:55396) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nElb3-0003pz-Qx for emacs-devel@gnu.org; Tue, 01 Feb 2022 00:20:53 -0500 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:30093) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nElax-0005xy-T5 for emacs-devel@gnu.org; Tue, 01 Feb 2022 00:20:51 -0500 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 84ACF44015B; Tue, 1 Feb 2022 00:20:33 -0500 (EST) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 25CDD44011B; Tue, 1 Feb 2022 00:20:32 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1643692832; bh=wzqil9hBnLhDZfZJU5yz+MaUHZOqvQjtdyFq90X6EnU=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=e/3TwWdZSf9MfPhl8RFAFBI75MJob5dMLdog0/qpaEpqzwIYnxOg6/PxWArTI5ZtQ oNOdILdWFZ+j9FoBfnR8jJxXmJP7QYJ7xcVX2pe6hcvKu4rNJSOQRilzJMolL/z7C6 UCdBXmh35hAz4V21mN2DtAQjG/7OqbNGWT59qIe4FZ32aWENXIzPoN91GVACGa1aHZ CccvFjMgTJk8BRSYLeTKlA+ba7v0jwjOG826l30T63wZ6LmJE+HRFCY3dmVLwWdAg+ UMWlFc9cawZo4Ax8EYgyXwmPy9iQvtFtPet0hhhlrtuJhC8GPaGP0JIcN6DItr01Fw q+NgoQk/68ilA== Original-Received: from pastel (76-10-138-212.dsl.teksavvy.com [76.10.138.212]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id EB3F7120807; Tue, 1 Feb 2022 00:20:31 -0500 (EST) In-Reply-To: <20220201021359.C439EC40717@vcs2.savannah.gnu.org> (Po Lu via Mailing list for Emacs changes's message of "Mon, 31 Jan 2022 21:13:59 -0500 (EST)") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:285719 Archived-At: > @@ -173,6 +173,7 @@ decoded. If `gui-get-selection' signals an error, return nil." > (unless (and (memq window-system '(x haiku)) > ;; gui-backend-selection-p might be unreliable on other > ;; window systems. > + (eq type 'CLIPBOARD) > (gui-backend-selection-owner-p type)) > (let ((request-type (if (memq window-system '(x pgtk)) > (or x-select-request-type The comment is weird. Is it meant to apply to the line of code *above* it? If so, please move it since we follow the convention to put comments *before* the code to which they apply. Also I suspect that you meant to say `gui-backend-selection-owner-p` rather than `gui-backend-selection-p` in the comment, right? BTW rather than use such tests we should probably change `gui-backend-selection-owner-p` so it can return yes/no/dontknow. Stefan