From unknown Fri Sep 12 08:42:23 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#39546 <39546@debbugs.gnu.org> To: bug#39546 <39546@debbugs.gnu.org> Subject: Status: 28.0.50; Do not require subr-x at run time Reply-To: bug#39546 <39546@debbugs.gnu.org> Date: Fri, 12 Sep 2025 15:42:23 +0000 retitle 39546 28.0.50; Do not require subr-x at run time reassign 39546 emacs submitter 39546 Tino Calancha severity 39546 wishlist tag 39546 patch wontfix thanks From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 09:00:21 2020 Received: (at submit) by debbugs.gnu.org; 10 Feb 2020 14:00:21 +0000 Received: from localhost ([127.0.0.1]:53839 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j19bm-00067K-Cp for submit@debbugs.gnu.org; Mon, 10 Feb 2020 09:00:21 -0500 Received: from lists.gnu.org ([209.51.188.17]:35861) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j19bk-00067D-Tn for submit@debbugs.gnu.org; Mon, 10 Feb 2020 09:00:17 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:52483) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j19bi-0003UO-7q for bug-gnu-emacs@gnu.org; Mon, 10 Feb 2020 09:00:16 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, URIBL_BLOCKED autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j19bc-0006Vd-HJ for bug-gnu-emacs@gnu.org; Mon, 10 Feb 2020 09:00:14 -0500 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]:45170) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j19bc-0006VE-8I for bug-gnu-emacs@gnu.org; Mon, 10 Feb 2020 09:00:08 -0500 Received: by mail-wr1-x442.google.com with SMTP id g3so6772779wrs.12 for ; Mon, 10 Feb 2020 06:00:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:mime-version; bh=JOfwG/bp3fRO6jNvIU3DJ95y+mqO11SpYtF/waTyJ1A=; b=OefKnmYQ5XcEX6YPjSRATFIWSgIjSrr+8uMVWtnGjDoxVc+PCwMKNsH0op9sqLDOBa UJz6mWJv0yNJpvINWxRvUYJdYtpOAc7LBYBzrG6W+G+11vLtC4cvSosI8gQVI2YrfP/q uyIRUEd1FRNKgfVXMKaQjlvoSrMKlk1NENVGs5H8yZZmv5v87dCdw2t7AYZO0uyLZhpD Kz+4LtZXH2rfF36xKAmqjsZxBH0Zr3flGy70pnPNGIOj0NLfDU6UcPEijQiYzibjO+8e Yrapj3h06nfN3C3o+tkVlk3llgdjYJc6Ei4JSmAMv8R5iCsv6I6O8AewqvEAMAS55ghU kgaw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=JOfwG/bp3fRO6jNvIU3DJ95y+mqO11SpYtF/waTyJ1A=; b=gos2my5Ign5oP0Y3Uw4PHEwk28iAxBfPqNwrLykHsxGR5VN6+jR2be8StCT/mSZWOe 9locfezsuk0SvvYWfLN0vGhawUQORYdTjfdqEYdiNcPvbh6vfKbKzvvhngj5rbhp/oGj /RoWkwiR4aGCPO7qiEKxqdYEVJkSYIB8sHRYIYFcn46y/ubLSbB4ev5ZHlGzC4e2BDoI DILyNzb+dEOzB2Zx0FEV5nrf7dUTAIFe0RLxwH3wjK1fP2/bFtgv3SIcyNGoyqU1BZVk kt6nA9NEnBqy+rQ3o8cEMdMPo+7aqMRfY6uIfyrIOVvxs87RXwUAj//rQzdpdRh90auv mtkw== X-Gm-Message-State: APjAAAWcJsDzjcEl3TxI6Yt15VhmakG0O5lF1EU6qiXcry9q018utC1r 2WbM7toihc57qkPfNkoNmtBzBDuCO5s= X-Google-Smtp-Source: APXvYqywrwd50jgjJAGwTlV11pFUL8WW/hlTQHyYU62BTTDWAx4icIr808pSr6NqSnLLY/WjVs10YQ== X-Received: by 2002:adf:f3cd:: with SMTP id g13mr2256531wrp.54.1581343206378; Mon, 10 Feb 2020 06:00:06 -0800 (PST) Received: from localhost.example.com (prg-ext-pat.suse.com. [213.151.95.130]) by smtp.gmail.com with ESMTPSA id e18sm674673wrw.70.2020.02.10.06.00.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Feb 2020 06:00:05 -0800 (PST) From: Tino Calancha To: bug-gnu-emacs@gnu.org Subject: 28.0.50; Do not require subr-x at run time Date: Mon, 10 Feb 2020 14:59:42 +0100 Message-ID: <87k14uwnjl.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::442 X-Spam-Score: 2.3 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: X-Debbugs-Cc: Tassilo Horn , Michael Albinus , Lars Magne Ingebrigtsen Severity: wishlist tags: patch This patch replaces (require subr-x) with (eval-when-compile (require 'subr-x)) on several files using just defsubst/defmacro from subr-x.el. Content analysis details: (2.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [URIs: x.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (tino.calancha[at]gmail.com) 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 1.0 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail) -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/, low trust [209.51.188.17 listed in list.dnswl.org] 2.0 SPOOFED_FREEMAIL No description available. X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) X-Debbugs-Cc: Tassilo Horn ,Michael Albinus ,Lars Magne Ingebrigtsen Severity: wishlist tags: patch This patch replaces (require subr-x) with (eval-when-compile (require 'subr-x)) on several files using just defsubst/defmacro from subr-x.el. In addition, it moves back replace-region-contents into subr.el: been a defun, and documented in the manual, then it fits better inside subr.el. --8<-----------------------------cut here---------------start------------->8--- commit 87abdb434ad892256c4a432eb86ac5628d253891 Author: Constantino Calancha Date: Mon Feb 10 14:19:10 2020 +0100 Do not require subr-x at run time Move back `replace-region-contents' to subr.el according with the convention for subr-x. * calendar/time-date.el * net/net-utils.el * net/nsm.el * net/tramp-compat.el: Require subr-x at compile time. * lisp/subr.el (replace-region-contents): Move it from subr-x.el. * lisp/emacs-lisp/json.el: Do not require subr-x since now `replace-region-contents' is loaded at start up. diff --git a/lisp/calendar/time-date.el b/lisp/calendar/time-date.el index e2402de801..b4b13037bf 100644 --- a/lisp/calendar/time-date.el +++ b/lisp/calendar/time-date.el @@ -37,7 +37,7 @@ ;;; Code: (require 'cl-lib) -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (defmacro with-decoded-time-value (varlist &rest body) "Decode a time value and bind it according to VARLIST, then eval BODY. diff --git a/lisp/emacs-lisp/subr-x.el b/lisp/emacs-lisp/subr-x.el index 044c9aada0..883607a549 100644 --- a/lisp/emacs-lisp/subr-x.el +++ b/lisp/emacs-lisp/subr-x.el @@ -254,34 +254,6 @@ string-remove-suffix (substring string 0 (- (length string) (length suffix))) string)) -(defun replace-region-contents (beg end replace-fn - &optional max-secs max-costs) - "Replace the region between BEG and END using REPLACE-FN. -REPLACE-FN runs on the current buffer narrowed to the region. It -should return either a string or a buffer replacing the region. - -The replacement is performed using `replace-buffer-contents' -which also describes the MAX-SECS and MAX-COSTS arguments and the -return value. - -Note: If the replacement is a string, it'll be placed in a -temporary buffer so that `replace-buffer-contents' can operate on -it. Therefore, if you already have the replacement in a buffer, -it makes no sense to convert it to a string using -`buffer-substring' or similar." - (save-excursion - (save-restriction - (narrow-to-region beg end) - (goto-char (point-min)) - (let ((repl (funcall replace-fn))) - (if (bufferp repl) - (replace-buffer-contents repl max-secs max-costs) - (let ((source-buffer (current-buffer))) - (with-temp-buffer - (insert repl) - (let ((tmp-buffer (current-buffer))) - (set-buffer source-buffer) - (replace-buffer-contents tmp-buffer max-secs max-costs))))))))) (provide 'subr-x) diff --git a/lisp/json.el b/lisp/json.el index 18d7fda882..e31928e825 100644 --- a/lisp/json.el +++ b/lisp/json.el @@ -55,7 +55,6 @@ ;;; Code: (require 'map) -(require 'subr-x) ;; Parameters diff --git a/lisp/net/net-utils.el b/lisp/net/net-utils.el index ef3651b033..780f34b028 100644 --- a/lisp/net/net-utils.el +++ b/lisp/net/net-utils.el @@ -44,7 +44,7 @@ ;; days is for /sbin to be a symlink to /usr/sbin, but we still need to ;; search both for older systems. -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (require 'cl-lib) (defun net-utils--executable-find-sbin (command) diff --git a/lisp/net/nsm.el b/lisp/net/nsm.el index 2d36c5e257..f85529f726 100644 --- a/lisp/net/nsm.el +++ b/lisp/net/nsm.el @@ -26,7 +26,7 @@ (require 'cl-lib) (require 'rmc) ; read-multiple-choice -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (require 'seq) (require 'map) diff --git a/lisp/net/tramp-compat.el b/lisp/net/tramp-compat.el index 87bcd08b85..8f74683dee 100644 --- a/lisp/net/tramp-compat.el +++ b/lisp/net/tramp-compat.el @@ -39,7 +39,7 @@ tramp-unload-file-name-handlers (require 'ls-lisp) ;; Due to `tramp-handle-insert-directory'. (require 'parse-time) (require 'shell) -(require 'subr-x) +(eval-when-compile (require 'subr-x)) ;; `temporary-file-directory' as function is introduced with Emacs 26.1. (declare-function tramp-handle-temporary-file-directory "tramp") diff --git a/lisp/subr.el b/lisp/subr.el index b5ec0de156..406cc50611 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -5768,6 +5768,35 @@ flatten-tree ;; for discoverability: (defalias 'flatten-list 'flatten-tree) +(defun replace-region-contents (beg end replace-fn + &optional max-secs max-costs) + "Replace the region between BEG and END using REPLACE-FN. +REPLACE-FN runs on the current buffer narrowed to the region. It +should return either a string or a buffer replacing the region. + +The replacement is performed using `replace-buffer-contents' +which also describes the MAX-SECS and MAX-COSTS arguments and the +return value. + +Note: If the replacement is a string, it'll be placed in a +temporary buffer so that `replace-buffer-contents' can operate on +it. Therefore, if you already have the replacement in a buffer, +it makes no sense to convert it to a string using +`buffer-substring' or similar." + (save-excursion + (save-restriction + (narrow-to-region beg end) + (goto-char (point-min)) + (let ((repl (funcall replace-fn))) + (if (bufferp repl) + (replace-buffer-contents repl max-secs max-costs) + (let ((source-buffer (current-buffer))) + (with-temp-buffer + (insert repl) + (let ((tmp-buffer (current-buffer))) + (set-buffer source-buffer) + (replace-buffer-contents tmp-buffer max-secs max-costs))))))))) + ;; The initial anchoring is for better performance in searching matches. (defconst regexp-unmatchable "\\`a\\`" "Standard regexp guaranteed not to match any string at all.") --8<-----------------------------cut here---------------end--------------->8--- In GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars) of 2020-02-10 built on localhost.example.com Repository revision: ac9acc1864b02b92de4eb2e98db7b5b0cd03e019 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12007000 System Description: openSUSE Tumbleweed From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 09:55:08 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 14:55:08 +0000 Received: from localhost ([127.0.0.1]:53939 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1ASq-0007MY-1I for submit@debbugs.gnu.org; Mon, 10 Feb 2020 09:55:08 -0500 Received: from mout.gmx.net ([212.227.15.18]:51761) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1ASn-0007Ks-Rz for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 09:55:06 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1581346498; bh=mf0mH6JrtS2D86UH2028L3MuEstkyrb+Yq5Hyaogj+s=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=O0rcj0Lh2qokd7u+PgXu0GnfndJoTG3BCHbLZhaGyFKwR7y9aceerbymBH7CLIXm8 NoeeZ3waQOXwR32yWyzwRE+fR960c57KQUOKCCX+4mXvk7gz2AbFJtsisTIFUMZ2uf xcuQVsdjnPMkKvPTKNj80bCwCMxNDQTeXLv1v/4c= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from detlef.gmx.de ([212.86.51.13]) by mail.gmx.com (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MV63g-1ituOC0rZO-00SAOa; Mon, 10 Feb 2020 15:54:58 +0100 From: Michael Albinus To: Tino Calancha Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> Date: Mon, 10 Feb 2020 15:54:56 +0100 In-Reply-To: <87k14uwnjl.fsf@gmail.com> (Tino Calancha's message of "Mon, 10 Feb 2020 14:59:42 +0100") Message-ID: <87eev24hmn.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:86cSrvzo4laidTbBqLgxOSEQj2cGVaKLAm12hPWEPBtWXMMnngY Z89rzdtRRfbB5Zi/0X0SoBPEv6MDyKZAPcLDkbBdS9CXrBMv7zq/MiuhNnHn8+Rx32EY9bo HX9kChjrI3Idc7aAGgPlPVmoL8s5WjaAjX3T0Zzk+9Q4YhK8fnj9bjciLevNdbgE4q2ugJ5 Ir2nAO6Yo4RcGsBlmhFdg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:6vamxE47vYs=:rgVXmSevuDtI7zKIHqRj0r 89jXlWT1YtIdSSALEC6KuZ2RvQh91nbCopAnL5G05jfa4hpW6DFj3wD02Bs/KzJ6foGsK5/cq M237SOC4+/RoScUlNGBvImEejvjyhOghS1jDSgssP3/mE9yC/KYvqXt1R/K5y6FIN2ls8VVOu 3U3rw4hIbjk7l+xaqZlmXw9PAAgZLr3SCMhg74axkPkWUbxLZQhUKTePOX0NB7E3CsDLAWpaB bkVq36xaQWscieSP7J+HR5nuKkJDIKQrMEPYds3FIQjqeeDBs9y6hUd3J/jg7iA992+DynY8a zZ6KAnaOOvGPlMc5mYMl4MlD+A8eYml0Ah2ohGKa3MiU4fpmmsgga99UY5nLvGAWP62vYYLVr InXMkFUu3w1NuSedGMCS6a8dE/XxKl0w7M1vZrN/bLB6kCfahFjx+GicuDpEwR/UX2WEI0SVx IcRtxn/bnFjYFGXA0QBsmdBO8OhBsV9Q9yztCLitjR6iH6ODsoa/r+wsxZQfQpVDKwMQgWA1H a9euRtsG/QQ/1sjEwovD/ee/WivGBfOsV+IzXVT8/NU161Pb9I6zfFfpo28Cjffq/Q0K6AsX0 vdEAIjxP4up0Ck9a7u30TKcjmjx/DfSyM0JmZHc3WYcTYN/KcveiEWZLTTK/8EgINKvGin6ut FQwVeSdXYliW8cOASjuRbWdgMdfbcPS/H53vT51GVf+zGSb+zpivK79a4kxoXPcEXnTwdgCyL O57xK0/iS2qs226SaSNN2vyk+TM4IWw1qlNbmQb6XquGhMwq4xyVGS5YA5uDoxfPOGTJ3KYB0 VFFnrgkqWCS62rONVxc15Pho7OnVgSd3noEF4uST/aXGO4uKdKrHbh7TCbTeEtpU88mf1Xagx QOFQ3hgAuyxc52JqNYu50JN8XKxgnXEmm6Vj4kmgKG7F1gAH7OZVAmmHxdAPeudac7XKk0+Bm J4timMDFZfUIwlQs8ewflZ37TFKwFlgD/9w4mKzBfBQrtfGNfnqYBFY1S01JJEcTAlaPdEERW D6B/iV7PgqlqTNvSYgOY75RVAG5drwBG9ATS5TafVUF369HTmIgAOAzaqjFIZR+R/0d5g9qtf VgFSa1jP9mNAY/gZoKY5gydqTXC+41+vAE7kkA2rPx2ycx0IGaO77VfeFwnH2k4FO/1I5DUnQ +WMuRul46bbOHxvy6APXBcXGRYudB+f7kZcgYza5WTe2/r6ddcevsGUgGyH3rHYdcCZbbSMN8 nrU0ks/jpXhSD+blF X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, lars magne ingebrigtsen , tassilo horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Tino Calancha writes: Hi Tino, > diff --git a/lisp/net/tramp-compat.el b/lisp/net/tramp-compat.el > index 87bcd08b85..8f74683dee 100644 > --- a/lisp/net/tramp-compat.el > +++ b/lisp/net/tramp-compat.el > @@ -39,7 +39,7 @@ tramp-unload-file-name-handlers > (require 'ls-lisp) ;; Due to `tramp-handle-insert-directory'. > (require 'parse-time) > (require 'shell) > -(require 'subr-x) > +(eval-when-compile (require 'subr-x)) > > ;; `temporary-file-directory' as function is introduced with Emacs 26.1. > (declare-function tramp-handle-temporary-file-directory "tramp") Tramp needs `string-join' and `string-empty-p' from subr-x.el. If we don't load it here, we must eval-when-compile it in almost all Tramp files, I believe. Hmm, what's so bad requiring it? (I know the general answer because both are defsubst'es, but I don't see the point here). From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 10:31:47 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 15:31:47 +0000 Received: from localhost ([127.0.0.1]:55227 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1B2I-000075-Sx for submit@debbugs.gnu.org; Mon, 10 Feb 2020 10:31:47 -0500 Received: from eggs.gnu.org ([209.51.188.92]:52362) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1B2G-00006s-8A for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 10:31:44 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:48916) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j1B2A-0002XN-TC; Mon, 10 Feb 2020 10:31:38 -0500 Received: from [176.228.60.248] (port=1394 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1j1B28-00080h-4C; Mon, 10 Feb 2020 10:31:36 -0500 Date: Mon, 10 Feb 2020 17:31:25 +0200 Message-Id: <831rr2cvci.fsf@gnu.org> From: Eli Zaretskii To: Tino Calancha In-reply-to: <87k14uwnjl.fsf@gmail.com> (message from Tino Calancha on Mon, 10 Feb 2020 14:59:42 +0100) Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, michael.albinus@gmx.de, tsdh@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Tino Calancha > Date: Mon, 10 Feb 2020 14:59:42 +0100 > Cc: lars magne ingebrigtsen , > michael albinus , tassilo horn > > In addition, it moves back replace-region-contents into subr.el: been a defun, > and documented in the manual, then it fits better inside subr.el. subr.el is preloaded, so doing that will enlarge the Emacs memory footprint. Is that function important enough to have it preloaded? Thanks. From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 12:26:24 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 17:26:24 +0000 Received: from localhost ([127.0.0.1]:55346 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1CpE-0005AG-0g for submit@debbugs.gnu.org; Mon, 10 Feb 2020 12:26:24 -0500 Received: from mail-wr1-f53.google.com ([209.85.221.53]:44668) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1CpB-0005A3-Dc for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 12:26:21 -0500 Received: by mail-wr1-f53.google.com with SMTP id m16so8758614wrx.11 for <39546@debbugs.gnu.org>; Mon, 10 Feb 2020 09:26:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:date:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=AvonKoH3+4dmc/g+fLa/L4eoXVYyqEGFKhQWePxkdZU=; b=cn+Xb9d69cv96P7UiZt6Uf08qXv72wAmi+s+vJCVU6aEaB9D4G9XelRzxFkTjNWhLn B5ToIYJcmeHykLbxvDgKI2vyinQHK+oyt0kdgkXg3dlIBAEKxHEtr2PFLNLGGLj00CBA yQugxxGgH3NrQU32lgcyl6cDVm61xoLeqq3jJ596cV5KjaF8//8Sh1hYgU+4dBqGzsfi 5XgHyFBnvTIaBua4AvUkmGnRwyEEeFm4FG34n+2KRSAfqSr05wfRcaTF954q1SK2VJXB rksGQxkFEYZAfVPiNNOiIGFU8uSdNwpooDaV/UdoI9L0YHSuShszx5eXcubzLhobZnEP MjKQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:date:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=AvonKoH3+4dmc/g+fLa/L4eoXVYyqEGFKhQWePxkdZU=; b=S7fq/pHNyGAk4mUg1GYmJeLMItPEhU4wfMZELhPu589ietWyr0DhBdp+Dbn7/PYVPE qjPQHTp/uybeEv5qj8acT2182TADw4s/sSyi6JIR1I7vcLB/TG9TItrrlFemuroFwHld pd+E5QEkzpDeyPR0/ZEaZWPhvIqhdzRK7P7oP+ylxkJNGY8hVQtL+VgVHJkkZY+iZ0FB wDFnyFU8nlaLG/57v9m9hIub34FFKwM40KT3i36xqTZRGja6ApXgYYMvsntnfx+w2J1P uTh19uhs+e5CHEMYcHZy1hnYlJFYXN8u77jRD7IWmjHq7N7AM26Bi0FRmoY8pZsTlBZc 1qXQ== X-Gm-Message-State: APjAAAWPpl1kKM5cXtwLUsO1KY5n8i/27s8oAf1PNRrYrttQ0ywU05H0 YoDT3mVzlLW+o1pwG0aD9uI= X-Google-Smtp-Source: APXvYqzzlzwDWdOdfRLVuZg3jZE1mLWBFDuXGIeY0iqFeyJXBNXneSpOma0EcYy1LIVIvN6h161BbA== X-Received: by 2002:adf:df0f:: with SMTP id y15mr3049671wrl.26.1581355575568; Mon, 10 Feb 2020 09:26:15 -0800 (PST) Received: from calancha-pc.dy.bbexcite.jp ([31.7.242.222]) by smtp.gmail.com with ESMTPSA id t9sm36817wmj.28.2020.02.10.09.26.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Feb 2020 09:26:14 -0800 (PST) From: Tino Calancha X-Google-Original-From: Tino Calancha Date: Mon, 10 Feb 2020 18:26:13 +0100 (CET) X-X-Sender: calancha@calancha-pc.dy.bbexcite.jp To: Eli Zaretskii Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time In-Reply-To: <831rr2cvci.fsf@gnu.org> Message-ID: References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Spam-Score: 1.1 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On Mon, 10 Feb 2020, Eli Zaretskii wrote: >> In addition, it moves back replace-region-contents into subr.el: been a defun, >> and documented in the manual, then it fits better inside subr.el. > > subr.el is preloaded, so doing that will enla [...] Content analysis details: (1.1 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (tino.calancha[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.221.53 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.221.53 listed in wl.mailspike.net] 1.1 MALFORMED_FREEMAIL Bad headers on message from free email service X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, tsdh@gnu.org, michael.albinus@gmx.de, Tino Calancha X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Mon, 10 Feb 2020, Eli Zaretskii wrote: >> In addition, it moves back replace-region-contents into subr.el: been a defun, >> and documented in the manual, then it fits better inside subr.el. > > subr.el is preloaded, so doing that will enlarge the Emacs memory > footprint. Is that function important enough to have it preloaded? According with its usage at Emacs source (only at json.el) I'd say the answer to your question is: not worth to be at subr.el. From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 12:35:47 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 17:35:47 +0000 Received: from localhost ([127.0.0.1]:55351 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1CyJ-0005O2-0n for submit@debbugs.gnu.org; Mon, 10 Feb 2020 12:35:47 -0500 Received: from mail-wm1-f41.google.com ([209.85.128.41]:35156) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1CyG-0005Nn-RH for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 12:35:45 -0500 Received: by mail-wm1-f41.google.com with SMTP id b17so161810wmb.0 for <39546@debbugs.gnu.org>; Mon, 10 Feb 2020 09:35:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:date:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=qDxKEdSvs/i08LxkLF1vkRoHmhJbokg2ERgrIKXksws=; b=X+A5GDWgbI0GB0XORPl6xZW0wHmZc4frffFUoPKJrpSJO7/cXTzRnG4RUBnsnwo/Ia zBo/SAR73r1G3znAnx1FNU5gVADPNb94WUuMNQEkPcJYQpPSJDu+F4ut/57qKMvBJ5vp qFivehx3iKl9TGz++8SuB0p4YvUXyPi2V8117RjwdKqs5eE+fnXoZvKU1xXhTBMCSXdT uLPY66H3AcWDhj7qTlDNqTEUhC6YrXtnfXnw5DId1UiMSlGZXzWu9rRrggb2da12dvbn HED6/WNk2zcs0W93Cng1RgXVZr/8fT7UUCSTUuec7/1QUjpcOA3k65Q/keqmsp8POcGQ 1dLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:date:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=qDxKEdSvs/i08LxkLF1vkRoHmhJbokg2ERgrIKXksws=; b=KtGyOPbpnj/UgslbJljqgPCcmC+9E5w+fl1Q6GYaHYfF+DrnjZ/+pDdWlfm0W6g6vn oT7irnRqkeCJmsG8TMRZtetkNJCAFtX/5ZWdWoCa84WUrC+ZXWLMidw0nk62fVp19T8G rQzuBZwFZ+xPQBNWYAATwh7zuv1/QXAoxtbFAIE839vEPm3uHjyTCWQRL7Ir6DEmlH+o jThDq68/OSuppGh7YQSWRSXfBXqb/ld4df4Y5/aCEZ9j0L0kpze7bn7uMPewDwwNKR1e ax10fv89o1+tLykooyHLdEFSyXlV5LrLLHpxV4M4JJcAiTlNc+7Mwv5VzptoOH9bkFtS mISQ== X-Gm-Message-State: APjAAAVIULh7h6/v0JtqqK/WCSOcSJhaTVf1LVQzBA/cYeupojxF9ZkA Ck2xIPuVTSw90/j9m+5WaBc= X-Google-Smtp-Source: APXvYqxLWWunFwRgL1U9moreG0y9qlIbOa2bcQ1qkYzIybK7Y2TkZbk73RtywS0fDFfEZIrNCmg3Rg== X-Received: by 2002:a7b:ce8b:: with SMTP id q11mr121850wmj.100.1581356138193; Mon, 10 Feb 2020 09:35:38 -0800 (PST) Received: from calancha-pc.dy.bbexcite.jp ([31.7.242.222]) by smtp.gmail.com with ESMTPSA id d16sm1654918wrg.27.2020.02.10.09.35.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Feb 2020 09:35:37 -0800 (PST) From: Tino Calancha X-Google-Original-From: Tino Calancha Date: Mon, 10 Feb 2020 18:35:36 +0100 (CET) X-X-Sender: calancha@calancha-pc.dy.bbexcite.jp To: Michael Albinus Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time In-Reply-To: <87eev24hmn.fsf@gmx.de> Message-ID: References: <87k14uwnjl.fsf@gmail.com> <87eev24hmn.fsf@gmx.de> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Spam-Score: 1.1 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On Mon, 10 Feb 2020, Michael Albinus wrote: > Tramp needs `string-join' and `string-empty-p' from subr-x.el. If we > don't load it here, we must eval-when-compile it in almost all Tramp > files, I believe. Content analysis details: (1.1 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (tino.calancha[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.128.41 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.128.41 listed in wl.mailspike.net] 1.1 MALFORMED_FREEMAIL Bad headers on message from free email service X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, lars magne ingebrigtsen , tassilo horn , Tino Calancha X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Mon, 10 Feb 2020, Michael Albinus wrote: > Tramp needs `string-join' and `string-empty-p' from subr-x.el. If we > don't load it here, we must eval-when-compile it in almost all Tramp > files, I believe. > Hmm, what's so bad requiring it? (I know the general answer because both > are defsubst'es, but I don't see the point here). My point is just to follow our convention for subr-x; of course, not a strong point, just a aesthetic one. From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 12:40:06 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 17:40:06 +0000 Received: from localhost ([127.0.0.1]:55355 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1D2U-0005U0-IY for submit@debbugs.gnu.org; Mon, 10 Feb 2020 12:40:06 -0500 Received: from eggs.gnu.org ([209.51.188.92]:38969) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1D2S-0005TR-3y for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 12:40:05 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:51413) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j1D2M-0006Eb-Lj; Mon, 10 Feb 2020 12:39:58 -0500 Received: from [176.228.60.248] (port=2303 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1j1D2L-0006Op-KI; Mon, 10 Feb 2020 12:39:58 -0500 Date: Mon, 10 Feb 2020 19:39:45 +0200 Message-Id: <83r1z2bau6.fsf@gnu.org> From: Eli Zaretskii To: Tino Calancha In-reply-to: (message from Tino Calancha on Mon, 10 Feb 2020 18:26:13 +0100 (CET)) Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, michael.albinus@gmx.de, tsdh@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Tino Calancha > Date: Mon, 10 Feb 2020 18:26:13 +0100 (CET) > cc: Tino Calancha , 39546@debbugs.gnu.org, > larsi@gnus.org, michael.albinus@gmx.de, tsdh@gnu.org > > On Mon, 10 Feb 2020, Eli Zaretskii wrote: > > > subr.el is preloaded, so doing that will enlarge the Emacs memory > > footprint. Is that function important enough to have it preloaded? > According with its usage at Emacs source (only at json.el) I'd say > the answer to your question is: not worth to be at subr.el. That's what I thought. So I suggest to find another file to host this function, if we want subr-x.el to have only macros and defsubst's. Thanks. From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 14:19:19 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 19:19:19 +0000 Received: from localhost ([127.0.0.1]:55419 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1EaV-0001N0-1R for submit@debbugs.gnu.org; Mon, 10 Feb 2020 14:19:19 -0500 Received: from eggs.gnu.org ([209.51.188.92]:37358) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1EaR-0001Mm-Tb for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 14:19:17 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:53149) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j1EaM-0003Vw-Lj; Mon, 10 Feb 2020 14:19:10 -0500 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]:43187) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.82) (envelope-from ) id 1j1EaL-0001ZY-Sp; Mon, 10 Feb 2020 14:19:10 -0500 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailauth.nyi.internal (Postfix) with ESMTP id 6821C2013C; Mon, 10 Feb 2020 14:19:09 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute7.internal (MEProxy); Mon, 10 Feb 2020 14:19:09 -0500 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedriedugdduudegucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufhfffgjkfgfgggtsehttdertddtredtnecuhfhrohhmpefvrghsshhi lhhoucfjohhrnhcuoehtshguhhesghhnuhdrohhrgheqnecukfhppeekgedrudefvddrud dthedrudekvdenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhr ohhmpehthhhorhhnodhmvghsmhhtphgruhhthhhpvghrshhonhgrlhhithihqdekieejfe ekjeekgedqieefhedvleekqdhtshguhheppehgnhhurdhorhhgsehfrghsthhmrghilhdr fhhm X-ME-Proxy: Received: from thinkpad-t440p (p548469b6.dip0.t-ipconnect.de [84.132.105.182]) by mail.messagingengine.com (Postfix) with ESMTPA id 40B793280063; Mon, 10 Feb 2020 14:19:07 -0500 (EST) From: Tassilo Horn To: Eli Zaretskii Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> Date: Mon, 10 Feb 2020 20:19:05 +0100 In-Reply-To: <83r1z2bau6.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 10 Feb 2020 19:39:45 +0200") Message-ID: <87wo8up7x2.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, michael.albinus@gmx.de, Tino Calancha X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Eli Zaretskii writes: >> > subr.el is preloaded, so doing that will enlarge the Emacs memory >> > footprint. Is that function important enough to have it preloaded? >> According with its usage at Emacs source (only at json.el) I'd say >> the answer to your question is: not worth to be at subr.el. > > That's what I thought. So I suggest to find another file to host this > function, if we want subr-x.el to have only macros and defsubst's. Given that it's only a wrapper around replace-buffer-contents which is always available, I think it shouldn't be hidden too much. AFAIK, I've put it in subr.el first and requests were made to move it to subr-x.el. I've already submitted patches to hindent (and I think to some other 3rd party package providing code formatting by replacing with the output of some formatting tool) using that function. Anyway, if it is going to be moved, I'd to ask you to move it in emacs-27 so that I can check for and fix external usages I know of without having to distinguish emacs versions. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 14:30:30 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 19:30:30 +0000 Received: from localhost ([127.0.0.1]:55428 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1ElK-0001eh-Es for submit@debbugs.gnu.org; Mon, 10 Feb 2020 14:30:30 -0500 Received: from mail-wr1-f51.google.com ([209.85.221.51]:34552) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1ElH-0001eR-Q8 for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 14:30:28 -0500 Received: by mail-wr1-f51.google.com with SMTP id t2so9287486wrr.1 for <39546@debbugs.gnu.org>; Mon, 10 Feb 2020 11:30:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:date:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=XrHlV/aXL3sLwzbhPBCYBJwM/WAU2XKjZhu759AqncU=; b=Opm6wngoeWhNkBvALGpvpvs+Ct7Yzg06aNlYKDGXVXVmVOgW4f+8s92lfIBLhtxU3T cKlQRwZ0xDpV8Vv8BuW0FE+pHXjwNjJFIn+/BFu1cKKeD3KORJhk6T23d0oJrTr1bU/K Upv45R9xEPqeFMo8qJ+BGNQxbXAmFSBJYo4JitRKWvt0XZD/jYY0p7Q/G3X6PWDn+yPj spwFxSmX51npvjPsMgHdHSH0g5mq14zqIOEWVY/Wcuwspvv6BiG3daDY5co2KF/DlEpd BVLGnvbWSmhZw40YaHMZiwpJEvk4TOmsfuM2uCtzTm1igsP154TeLvQVPm0yPCW6EXF4 aavA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:date:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=XrHlV/aXL3sLwzbhPBCYBJwM/WAU2XKjZhu759AqncU=; b=NmwLxleTV3tp8gAGnrR+Gx78lCk03nIIRAdkbPSCVui/oPwvs85O8W5O++4WD+r6gF cSZHbR424MQuzTqsClW9xX9hsAUuD+QpxSYKrrJihEmWgiNhcQOHz/TnG3T8DRuGdcXy mLUkc1ZOC/fZC+lNHt4WfgPjsBB/fPLmcBs86E3Hr1POyXJe69gbKB8LOjxBtq6VBQV8 6UqxQt39zgTisecgCUq+LKDi2gKQvt/UACVLVE3S+4jaDXk8s2xxC0JK5D6/gLBksIVe aDgLO3YOLJVekAPaQxjgi3u0jn3R13GWyxI9Gn1EedNK7vUci6ipxYZb0S1XZkC3pjML wrWg== X-Gm-Message-State: APjAAAWIaWcMI2I6fWhtK9/LABSh6TurPFci8A+KHpLy3VyMnGFguJcE fT2YAuj87Y058KpUKTrIXGI= X-Google-Smtp-Source: APXvYqxuW8nXL08U3oUrTPXRq1MeGgnXKTXxz+Z+Xk9QyLuybGlD53Hnvf05+3bci28BfHxwnOo74Q== X-Received: by 2002:a05:6000:1012:: with SMTP id a18mr3433366wrx.113.1581363021936; Mon, 10 Feb 2020 11:30:21 -0800 (PST) Received: from calancha-pc.dy.bbexcite.jp ([31.7.242.222]) by smtp.gmail.com with ESMTPSA id b18sm1877375wru.50.2020.02.10.11.30.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Feb 2020 11:30:21 -0800 (PST) From: Tino Calancha X-Google-Original-From: Tino Calancha Date: Mon, 10 Feb 2020 20:30:19 +0100 (CET) X-X-Sender: calancha@calancha-pc.dy.bbexcite.jp To: Eli Zaretskii Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time In-Reply-To: <83r1z2bau6.fsf@gnu.org> Message-ID: References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Spam-Score: 2.2 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On Mon, 10 Feb 2020, Eli Zaretskii wrote: >> From: Tino Calancha >> Date: Mon, 10 Feb 2020 18:26:13 +0100 (CET) >> cc: Tino Calancha , 39546@debbugs.gnu.org, >> larsi@gnus.org, michael.albinus@gmx.de, tsdh@gnu.org >> >> On Mon, 10 Feb 2020 [...] Content analysis details: (2.2 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [URIs: gmx.de] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (tino.calancha[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [209.85.221.51 listed in list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.221.51 listed in wl.mailspike.net] 1.1 MALFORMED_FREEMAIL Bad headers on message from free email service 1.0 FREEMAIL_REPLY From and body contain different freemails X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, tsdh@gnu.org, michael.albinus@gmx.de, Tino Calancha X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On Mon, 10 Feb 2020, Eli Zaretskii wrote: >> From: Tino Calancha >> Date: Mon, 10 Feb 2020 18:26:13 +0100 (CET) >> cc: Tino Calancha , 39546@debbugs.gnu.org, >> larsi@gnus.org, michael.albinus@gmx.de, tsdh@gnu.org >> >> On Mon, 10 Feb 2020, Eli Zaretskii wrote: >> >>> subr.el is preloaded, so doing that will enlarge the Emacs memory >>> footprint. Is that function important enough to have it preloaded? >> According with its usage at Emacs source (only at json.el) I'd say >> the answer to your question is: not worth to be at subr.el. > > That's what I thought. So I suggest to find another file to host this > function, if we want subr-x.el to have only macros and defsubst's. replace.el is a good agreement between subr-x.el (it's a defun, so it doesn't fit well there) and subr.el. As subr.el, replace.el is also loaded at start time, but it's ~ half size, and more important than that, it's all about replacing in Emacs. From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 14:55:29 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 19:55:29 +0000 Received: from localhost ([127.0.0.1]:55488 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1F9U-0002Jc-RW for submit@debbugs.gnu.org; Mon, 10 Feb 2020 14:55:29 -0500 Received: from eggs.gnu.org ([209.51.188.92]:33419) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1F9S-0002JN-NJ for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 14:55:26 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:53825) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j1F9N-0000JG-Fb; Mon, 10 Feb 2020 14:55:21 -0500 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]:56869) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.82) (envelope-from ) id 1j1F9I-0005lw-76; Mon, 10 Feb 2020 14:55:17 -0500 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailauth.nyi.internal (Postfix) with ESMTP id CF4F821F92; Mon, 10 Feb 2020 14:55:15 -0500 (EST) Received: from imap34 ([10.202.2.84]) by compute7.internal (MEProxy); Mon, 10 Feb 2020 14:55:15 -0500 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedriedugdduvdduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvffutgesthdtredtreertdenucfhrhhomhepfdfvrghs shhilhhoucfjohhrnhdfuceothhsughhsehgnhhurdhorhhgqeenucffohhmrghinhepvg hlrdgrshenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhm pehthhhorhhnodhmvghsmhhtphgruhhthhhpvghrshhonhgrlhhithihqdekieejfeekje ekgedqieefhedvleekqdhtshguhheppehgnhhurdhorhhgsehfrghsthhmrghilhdrfhhm X-ME-Proxy: Received: by mailuser.nyi.internal (Postfix, from userid 501) id 68A541460061; Mon, 10 Feb 2020 14:55:15 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.1.7-802-g7a41c81-fmstable-20200203v1 Mime-Version: 1.0 Message-Id: <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> In-Reply-To: References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> Date: Mon, 10 Feb 2020 20:54:45 +0100 From: "Tassilo Horn" To: "Tino Calancha" , "Eli Zaretskii" Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, michael.albinus@gmx.de X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Am Mo, 10. Feb 2020, um 20:30, schrieb Tino Calancha: > replace.el is a good agreement between subr-x.el (it's a defun, so > it doesn't fit well there) and subr.el. > > As subr.el, replace.el is also loaded at start time, but it's ~ half size, > and more important than that, it's all about replacing in Emacs. Sounds good to me! Thanks, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 15:00:06 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 20:00:06 +0000 Received: from localhost ([127.0.0.1]:55492 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1FDy-0002Qj-F9 for submit@debbugs.gnu.org; Mon, 10 Feb 2020 15:00:06 -0500 Received: from eggs.gnu.org ([209.51.188.92]:45459) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1FDw-0002Pk-B2 for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 15:00:04 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:53874) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j1FDr-00019A-1b; Mon, 10 Feb 2020 14:59:59 -0500 Received: from [176.228.60.248] (port=3116 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1j1FDi-0001N2-L9; Mon, 10 Feb 2020 14:59:56 -0500 Date: Mon, 10 Feb 2020 21:59:39 +0200 Message-Id: <83mu9qb4d0.fsf@gnu.org> From: Eli Zaretskii To: Tassilo Horn In-reply-to: <87wo8up7x2.fsf@gnu.org> (message from Tassilo Horn on Mon, 10 Feb 2020 20:19:05 +0100) Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <87wo8up7x2.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, michael.albinus@gmx.de, tino.calancha@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Tassilo Horn > Cc: Tino Calancha , 39546@debbugs.gnu.org, > larsi@gnus.org, michael.albinus@gmx.de > Date: Mon, 10 Feb 2020 20:19:05 +0100 > > I've already submitted patches to hindent (and I think to some other 3rd > party package providing code formatting by replacing with the output of > some formatting tool) using that function. > > Anyway, if it is going to be moved, I'd to ask you to move it in > emacs-27 so that I can check for and fix external usages I know of > without having to distinguish emacs versions. Then maybe we shouldn't move it, just for these reasons. From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 15:18:54 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 20:18:54 +0000 Received: from localhost ([127.0.0.1]:55498 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1FWA-0002s7-5A for submit@debbugs.gnu.org; Mon, 10 Feb 2020 15:18:54 -0500 Received: from eggs.gnu.org ([209.51.188.92]:38434) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1FW6-0002rt-JI for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 15:18:53 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:54271) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j1FW0-0004EM-Lb; Mon, 10 Feb 2020 15:18:44 -0500 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]:50055) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.82) (envelope-from ) id 1j1FVz-0000rB-Q7; Mon, 10 Feb 2020 15:18:43 -0500 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailauth.nyi.internal (Postfix) with ESMTP id 51A9121FE5; Mon, 10 Feb 2020 15:18:43 -0500 (EST) Received: from imap34 ([10.202.2.84]) by compute7.internal (MEProxy); Mon, 10 Feb 2020 15:18:43 -0500 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedriedugdduvdeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvffutgesthdtredtreertdenucfhrhhomhepfdfvrghs shhilhhoucfjohhrnhdfuceothhsughhsehgnhhurdhorhhgqeenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhorhhnodhmvghsmhhtphgr uhhthhhpvghrshhonhgrlhhithihqdekieejfeekjeekgedqieefhedvleekqdhtshguhh eppehgnhhurdhorhhgsehfrghsthhmrghilhdrfhhm X-ME-Proxy: Received: by mailuser.nyi.internal (Postfix, from userid 501) id AABD41460061; Mon, 10 Feb 2020 15:18:42 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.1.7-802-g7a41c81-fmstable-20200203v1 Mime-Version: 1.0 Message-Id: In-Reply-To: <83mu9qb4d0.fsf@gnu.org> References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <87wo8up7x2.fsf@gnu.org> <83mu9qb4d0.fsf@gnu.org> Date: Mon, 10 Feb 2020 21:17:08 +0100 From: "Tassilo Horn" To: "Eli Zaretskii" Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, michael.albinus@gmx.de, Tino Calancha X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Am Mo, 10. Feb 2020, um 20:59, schrieb Eli Zaretskii: > > From: Tassilo Horn > > Cc: Tino Calancha , 39546@debbugs.gnu.org, > > larsi@gnus.org, michael.albinus@gmx.de > > Date: Mon, 10 Feb 2020 20:19:05 +0100 > > > > I've already submitted patches to hindent (and I think to some other 3rd > > party package providing code formatting by replacing with the output of > > some formatting tool) using that function. > > > > Anyway, if it is going to be moved, I'd to ask you to move it in > > emacs-27 so that I can check for and fix external usages I know of > > without having to distinguish emacs versions. > > Then maybe we shouldn't move it, just for these reasons. If we all think that replace.el is the right place and it has the benefit of being loaded at startup, then I'm all for it. The hindent PR is not yet merged anyway, and the other one was quickly accepted, so an addendum patch will be, too. I'd like to see more usages of that function. Basically every package providing support for external formatters should use it, e.g., I'm going to submit a patch for rust-mode providing formatting using rustfmt anytime soon. So better change it now than regretting that multiple not so uncommon packages require subr-x at runtime. Bye, Tassilo From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 15:34:56 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 20:34:56 +0000 Received: from localhost ([127.0.0.1]:55512 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1Flg-0003HP-3e for submit@debbugs.gnu.org; Mon, 10 Feb 2020 15:34:56 -0500 Received: from mail-wr1-f65.google.com ([209.85.221.65]:34307) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1Fle-0003HD-Cq for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 15:34:55 -0500 Received: by mail-wr1-f65.google.com with SMTP id t2so9493845wrr.1 for <39546@debbugs.gnu.org>; Mon, 10 Feb 2020 12:34:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=zKtpXyzVSOVKIov2haQuHTsCgetMI8w5hlA+Fq9S5Fo=; b=KmsCow7zv/AkrYERE5kfmFB7bqOX5haKzcI9lCKokBCNBRqfY+TftJFJrrVwt9mwAp yy33JTk13VQv5PAMykXUuw4vxvDOVDt7nAv2DkLcjXdft+6/B9txx0dtwsCg7zh7yFZi fJFR4vyXpbVUd9wOfobLulKowhGeOodiImv/RKLxXu/sR54EwTpBItiHUtwgVsKPzKhQ +7gvgzxsqDqYJ8jA1knPifAIY/j7fEV+f1aNzreLI3BneonTjNBdghmhuV4gjOpeo1cR W3XinkrFSpZzUQsUyq0bmnBoJIgVymOIPLSidOvrd5p+fqFj37zbI9gbWAU1uSbAFpRJ Rd8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=zKtpXyzVSOVKIov2haQuHTsCgetMI8w5hlA+Fq9S5Fo=; b=Sj3lYdzm0odl8W0JacC2aHfigbw4JhYCuKzp2yU5Y9n8Jbd1htq54R1lRQRb4niYqY hH2mAKv34RkkcTQD1CJ4Vu6QyGUmeeMiVzfipbDRlYqUvrM19HLSqJL+M5eptz/ruHPc m816HYCUuDx9Su7OQbU9FB6rX+RhlvJvl3g+/MZglO1ugSpxAePR9z+J4x0qR8GD17LF w5TtrB8+BDb7lL/IHcMc6Ziqe3YMpyFYOWnwFd8TEpt3mZbFHE6l5mWEf/v/BOD3yTT0 2ckj1kIZxzB6ubuBXjBCvI+SzDsRuOOeHv02WqbDz0TqL3ThljpvFb7r6pdollIllhh0 B+DQ== X-Gm-Message-State: APjAAAXiz44nAqcS4IFeNRCZfCqXamUCgnzPa9D/L/7F8wMZobQWboZ1 kBk45Bmd53kblEI4l75MaBs= X-Google-Smtp-Source: APXvYqyisDkGQj6+21EA7DKXqjP9KJ27mT/bHE+EsuCcosVHbBemN+h1pf7pFHou/bnqUJ2dRajAaQ== X-Received: by 2002:adf:e542:: with SMTP id z2mr3765453wrm.346.1581366888304; Mon, 10 Feb 2020 12:34:48 -0800 (PST) Received: from localhost.example.com ([31.7.242.222]) by smtp.gmail.com with ESMTPSA id z25sm652621wmf.14.2020.02.10.12.34.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Feb 2020 12:34:47 -0800 (PST) From: Tino Calancha To: "Tassilo Horn" Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> Date: Mon, 10 Feb 2020 21:34:46 +0100 In-Reply-To: <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> (Tassilo Horn's message of "Mon, 10 Feb 2020 20:54:45 +0100") Message-ID: <87ftfiyye1.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, Eli Zaretskii , michael.albinus@gmx.de, larsi@gnus.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) "Tassilo Horn" writes: > Am Mo, 10. Feb 2020, um 20:30, schrieb Tino Calancha: >> replace.el is a good agreement between subr-x.el (it's a defun, so >> it doesn't fit well there) and subr.el. >> >> As subr.el, replace.el is also loaded at start time, but it's ~ half size, >> and more important than that, it's all about replacing in Emacs. > > Sounds good to me! Here is the updated patch: - It deletes the cookie from subr-x (yes, we have one for when-let) - Move replace-region-contents inside replace.el (loaded at startup) - Add all required (eval-when...(req.. 'subr-x)) at tramp files - Replaced loading subr-x at run time with compile time for some other files I have run the testsuite without surprises. --8<-----------------------------cut here---------------start------------->8--- commit f6a7a4fc673f77724ccf0d7ae1fdb164328afc68 Author: Constantino Calancha Date: Mon Feb 10 21:19:29 2020 +0100 Do not require subr-x at run time Move back `replace-region-contents' to subr.el according with the convention for subr-x (Bug#39546). * lisp/subr-x.el (replace-region-contents): Delete it. (when-let): Delete autoload cookie. * calendar/time-date.el * net/net-utils.el * net/nsm.el * net/tramp-compat.el * lisp/net/mailcap.el * lisp/net/tramp-adb.el * lisp/net/tramp-cmds.el * lisp/net/tramp-gvfs.el * lisp/net/tramp-rclone.el * lisp/net/tramp-sh.el * lisp/net/tramp-smb.el * lisp/net/tramp-sudoedit.el * lisp/net/tramp.el: Require subr-x at compile time. * lisp/replace.el (replace-region-contents): Move it from subr-x.el. * lisp/emacs-lisp/json.el: Do not require subr-x since now `replace-region-contents' is loaded at start up. diff --git a/lisp/calendar/time-date.el b/lisp/calendar/time-date.el index e2402de801..b4b13037bf 100644 --- a/lisp/calendar/time-date.el +++ b/lisp/calendar/time-date.el @@ -37,7 +37,7 @@ ;;; Code: (require 'cl-lib) -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (defmacro with-decoded-time-value (varlist &rest body) "Decode a time value and bind it according to VARLIST, then eval BODY. diff --git a/lisp/emacs-lisp/subr-x.el b/lisp/emacs-lisp/subr-x.el index 044c9aada0..2c1415ab2a 100644 --- a/lisp/emacs-lisp/subr-x.el +++ b/lisp/emacs-lisp/subr-x.el @@ -182,7 +182,6 @@ if-let (setq spec (list spec))) (list 'if-let* spec then (macroexp-progn else))) -;;;###autoload (defmacro when-let (spec &rest body) "Bind variables according to SPEC and conditionally evaluate BODY. Evaluate each binding in turn, stopping if a binding value is nil. @@ -254,34 +253,6 @@ string-remove-suffix (substring string 0 (- (length string) (length suffix))) string)) -(defun replace-region-contents (beg end replace-fn - &optional max-secs max-costs) - "Replace the region between BEG and END using REPLACE-FN. -REPLACE-FN runs on the current buffer narrowed to the region. It -should return either a string or a buffer replacing the region. - -The replacement is performed using `replace-buffer-contents' -which also describes the MAX-SECS and MAX-COSTS arguments and the -return value. - -Note: If the replacement is a string, it'll be placed in a -temporary buffer so that `replace-buffer-contents' can operate on -it. Therefore, if you already have the replacement in a buffer, -it makes no sense to convert it to a string using -`buffer-substring' or similar." - (save-excursion - (save-restriction - (narrow-to-region beg end) - (goto-char (point-min)) - (let ((repl (funcall replace-fn))) - (if (bufferp repl) - (replace-buffer-contents repl max-secs max-costs) - (let ((source-buffer (current-buffer))) - (with-temp-buffer - (insert repl) - (let ((tmp-buffer (current-buffer))) - (set-buffer source-buffer) - (replace-buffer-contents tmp-buffer max-secs max-costs))))))))) (provide 'subr-x) diff --git a/lisp/json.el b/lisp/json.el index 18d7fda882..e31928e825 100644 --- a/lisp/json.el +++ b/lisp/json.el @@ -55,7 +55,6 @@ ;;; Code: (require 'map) -(require 'subr-x) ;; Parameters diff --git a/lisp/net/mailcap.el b/lisp/net/mailcap.el index 5fe5b4d3a5..75c91946e4 100644 --- a/lisp/net/mailcap.el +++ b/lisp/net/mailcap.el @@ -29,6 +29,7 @@ ;;; Code: +(eval-when-compile (require 'subr-x)) (autoload 'mail-header-parse-content-type "mail-parse") (defgroup mailcap nil diff --git a/lisp/net/net-utils.el b/lisp/net/net-utils.el index ef3651b033..780f34b028 100644 --- a/lisp/net/net-utils.el +++ b/lisp/net/net-utils.el @@ -44,7 +44,7 @@ ;; days is for /sbin to be a symlink to /usr/sbin, but we still need to ;; search both for older systems. -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (require 'cl-lib) (defun net-utils--executable-find-sbin (command) diff --git a/lisp/net/nsm.el b/lisp/net/nsm.el index 2d36c5e257..f85529f726 100644 --- a/lisp/net/nsm.el +++ b/lisp/net/nsm.el @@ -26,7 +26,7 @@ (require 'cl-lib) (require 'rmc) ; read-multiple-choice -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (require 'seq) (require 'map) diff --git a/lisp/net/tramp-adb.el b/lisp/net/tramp-adb.el index aa7fe147c2..60c46f1224 100644 --- a/lisp/net/tramp-adb.el +++ b/lisp/net/tramp-adb.el @@ -33,6 +33,7 @@ ;;; Code: +(eval-when-compile (require 'subr-x)) (require 'tramp) ;;;###tramp-autoload diff --git a/lisp/net/tramp-cmds.el b/lisp/net/tramp-cmds.el index b4dca2321c..871c215e87 100644 --- a/lisp/net/tramp-cmds.el +++ b/lisp/net/tramp-cmds.el @@ -29,6 +29,7 @@ ;;; Code: (require 'tramp) +(eval-when-compile (require 'subr-x)) ;; Pacify byte-compiler. (declare-function mml-mode "mml") diff --git a/lisp/net/tramp-compat.el b/lisp/net/tramp-compat.el index 87bcd08b85..8f74683dee 100644 --- a/lisp/net/tramp-compat.el +++ b/lisp/net/tramp-compat.el @@ -39,7 +39,7 @@ tramp-unload-file-name-handlers (require 'ls-lisp) ;; Due to `tramp-handle-insert-directory'. (require 'parse-time) (require 'shell) -(require 'subr-x) +(eval-when-compile (require 'subr-x)) ;; `temporary-file-directory' as function is introduced with Emacs 26.1. (declare-function tramp-handle-temporary-file-directory "tramp") diff --git a/lisp/net/tramp-gvfs.el b/lisp/net/tramp-gvfs.el index 0d800cb42b..5b037fb94b 100644 --- a/lisp/net/tramp-gvfs.el +++ b/lisp/net/tramp-gvfs.el @@ -102,6 +102,7 @@ (declare-function dbus-get-unique-name "dbusbind.c") (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) (require 'dbus) (require 'url-parse) diff --git a/lisp/net/tramp-rclone.el b/lisp/net/tramp-rclone.el index 445098a5bc..b7c99829ed 100644 --- a/lisp/net/tramp-rclone.el +++ b/lisp/net/tramp-rclone.el @@ -36,6 +36,7 @@ ;;; Code: (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) ;;;###tramp-autoload diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 5a3abc31ea..0c5bc72deb 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -32,6 +32,7 @@ ;;; Code: (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) (declare-function dired-remove-file "dired-aux") diff --git a/lisp/net/tramp-smb.el b/lisp/net/tramp-smb.el index f02be394a7..43e775b921 100644 --- a/lisp/net/tramp-smb.el +++ b/lisp/net/tramp-smb.el @@ -28,6 +28,7 @@ ;;; Code: (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) ;; Define SMB method ... diff --git a/lisp/net/tramp-sudoedit.el b/lisp/net/tramp-sudoedit.el index f258ad6b93..6ea52bedf8 100644 --- a/lisp/net/tramp-sudoedit.el +++ b/lisp/net/tramp-sudoedit.el @@ -34,6 +34,7 @@ ;;; Code: +(eval-when-compile (require 'subr-x)) (require 'tramp) ;;;###tramp-autoload diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 19d36c3a97..0783eda09e 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -60,6 +60,7 @@ (require 'tramp-compat) (require 'tramp-integration) (require 'trampver) +(eval-when-compile (require 'subr-x)) ;; Pacify byte-compiler. (require 'cl-lib) diff --git a/lisp/replace.el b/lisp/replace.el index a0b050637e..74c54a0b80 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -743,6 +743,35 @@ replace-regexp (if (use-region-p) (region-noncontiguous-p))))) (perform-replace regexp to-string nil t delimited nil nil start end backward region-noncontiguous-p)) +(defun replace-region-contents (beg end replace-fn + &optional max-secs max-costs) + "Replace the region between BEG and END using REPLACE-FN. +REPLACE-FN runs on the current buffer narrowed to the region. It +should return either a string or a buffer replacing the region. + +The replacement is performed using `replace-buffer-contents' +which also describes the MAX-SECS and MAX-COSTS arguments and the +return value. + +Note: If the replacement is a string, it'll be placed in a +temporary buffer so that `replace-buffer-contents' can operate on +it. Therefore, if you already have the replacement in a buffer, +it makes no sense to convert it to a string using +`buffer-substring' or similar." + (save-excursion + (save-restriction + (narrow-to-region beg end) + (goto-char (point-min)) + (let ((repl (funcall replace-fn))) + (if (bufferp repl) + (replace-buffer-contents repl max-secs max-costs) + (let ((source-buffer (current-buffer))) + (with-temp-buffer + (insert repl) + (let ((tmp-buffer (current-buffer))) + (set-buffer source-buffer) + (replace-buffer-contents tmp-buffer max-secs max-costs))))))))) + (defvar regexp-history nil "History list for some commands that read regular expressions. --8<-----------------------------cut here---------------end--------------->8--- From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 15:49:27 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 20:49:27 +0000 Received: from localhost ([127.0.0.1]:55516 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1Fzi-0003bp-Pm for submit@debbugs.gnu.org; Mon, 10 Feb 2020 15:49:26 -0500 Received: from mail-wr1-f68.google.com ([209.85.221.68]:42061) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1Fzh-0003bc-I2 for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 15:49:26 -0500 Received: by mail-wr1-f68.google.com with SMTP id k11so9477135wrd.9 for <39546@debbugs.gnu.org>; Mon, 10 Feb 2020 12:49:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=BTSbQMBETts8g4pWYahzUrJsvqRLX+Nu1R6MEBrVUV8=; b=cbmRAzf8fP3Y5s/zy1ELaOXU2YZ6ZapBsYXp2D0LNZzCtZNMOHvNemf+gH1eTNTVDg kRM7NOCX0/ZlKCbCNTk1tovGAqGFf1TN5f0qUG3ZQ/xb+hIlUhxLtbd4Bz5D2rOXOn6g 3Ub4BwHNGa/mYCmUFGzGA8ZPYBHkUH7ybURCA4Vor/n3jaE+pM4ES4AnEeMTmyiLXolV U0dY0HOWXyW1lLUCwbdSws2XHg9Lf4gbe1cDeU3xy2fPMIbOTDORA6Qr7hy2Epkd0z50 j8uoHH0gwMgvi/HW+Fg2dHqSe2rSg9KxQredOEhYsFF4wqLdlJ5KYANVNEX7t0Hg9b40 BGJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=BTSbQMBETts8g4pWYahzUrJsvqRLX+Nu1R6MEBrVUV8=; b=TNsaXS2+2MA/5jH20DLlL0HYqqKbEyizWzY2gP83aLQ3phRTOZZhBYAO4F2tMqQvVL p8bc3BCCJjMkjyjR1EnfnNjVbDpLUbLmAaZ/O8eUIMKA0ywC5CNhjSDcc4UPJ5nnB86p l5BZVNTqKi4du2E5Vib8XzJqRXAfT1M1I7MaQYW3Ueh7xth9QR0vHI+6UWiMT90i1yCR g7stXg7vx6k2tduXpBP3ikYHYRh9wQO+VDEuz8nXeZeMsA0+6YtUV1VnJwFdhQ6Kp6JA yvaJDz9lPo/OcatPWOPixgRMAczAo6GLuMmGZi36GMr/2W6T9T4EP2y+pZo+h18X+P6N Hk3Q== X-Gm-Message-State: APjAAAW/dRoh8ykt+qZJDyaADQ9N+/qIc/Xh8oosAhg1om/9V2uD3ld7 3mb/5jYUl9j6ARXKsctsvDo= X-Google-Smtp-Source: APXvYqyk+0HrtG9Wwnp+nFk95s63gtoAgrRJHNbei7ofwslDTikOkyVCDsDO3O0VvTJxWIn/mzTuuA== X-Received: by 2002:a5d:4dc5:: with SMTP id f5mr3975564wru.114.1581367759625; Mon, 10 Feb 2020 12:49:19 -0800 (PST) Received: from localhost.example.com ([31.7.242.222]) by smtp.gmail.com with ESMTPSA id f11sm680971wml.3.2020.02.10.12.49.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Feb 2020 12:49:19 -0800 (PST) From: Tino Calancha To: "Tassilo Horn" Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> <87ftfiyye1.fsf@gmail.com> Date: Mon, 10 Feb 2020 21:49:18 +0100 In-Reply-To: <87ftfiyye1.fsf@gmail.com> (Tino Calancha's message of "Mon, 10 Feb 2020 21:34:46 +0100") Message-ID: <87d0amyxpt.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, Eli Zaretskii , michael.albinus@gmx.de, larsi@gnus.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Tino Calancha writes: > "Tassilo Horn" writes: > >> Am Mo, 10. Feb 2020, um 20:30, schrieb Tino Calancha: >>> replace.el is a good agreement between subr-x.el (it's a defun, so >>> it doesn't fit well there) and subr.el. >>> >>> As subr.el, replace.el is also loaded at start time, but it's ~ half size, >>> and more important than that, it's all about replacing in Emacs. >> >> Sounds good to me! > > Here is the updated patch: > - It deletes the cookie from subr-x (yes, we have one for when-let) > - Move replace-region-contents inside replace.el (loaded at startup) > - Add all required (eval-when...(req.. 'subr-x)) at tramp files > - Replaced loading subr-x at run time with compile time for some other files > > I have run the testsuite without surprises. Well, actually there was a surprise, but who don't like surprises after all! I missed this one (it was relying on the whe-let cookie): diff --git a/lisp/image/exif.el b/lisp/image/exif.el index 642bc58321..27ad616146 100644 --- a/lisp/image/exif.el +++ b/lisp/image/exif.el @@ -62,6 +62,7 @@ ;;; Code: (require 'cl-lib) +(eval-when-compile (require 'subr-x)) (defvar exif-tag-alist '((11 processing-software) From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 10 16:00:32 2020 Received: (at 39546) by debbugs.gnu.org; 10 Feb 2020 21:00:32 +0000 Received: from localhost ([127.0.0.1]:55532 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1GAR-0003uL-Kw for submit@debbugs.gnu.org; Mon, 10 Feb 2020 16:00:32 -0500 Received: from mail-wm1-f68.google.com ([209.85.128.68]:52644) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j1GAP-0003u6-H9 for 39546@debbugs.gnu.org; Mon, 10 Feb 2020 16:00:30 -0500 Received: by mail-wm1-f68.google.com with SMTP id p9so799170wmc.2 for <39546@debbugs.gnu.org>; Mon, 10 Feb 2020 13:00:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=B8/pre19JLue+Ec23GOr26kiB1dq4GRWabQtkGUY4uU=; b=X808d/Ma/qnXPU1cqdTTRuaQG/9e2CPb/FOFWHVXsxqSy+h0LHEEQ+VwDBee+1mi9K M2bsUWTRy/u2+Es0Q5Vo8WFKW3Rb8EmZB3znRD98iX30OP8MdsP/IKNrj9gD9p8XJUuS oR5PHFBCidVvRZ87gDhRaWwD+qWPEdPPaSfmxYyob29mG3TipZfGgxgjZyJcuOumT+H3 vb5HRNKxBqz0xgMTBo/U5Sh1Gjsa8c3TQQciOy3QPzbHC4hmeo3TBCBLkd9goEybRwtV kpO0QbS2HUi3lrMCd4x8pa9lO308OI77RI9Dg/6k1E+cayVPavHCrEMHs7iiWiNWFu9W JUug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=B8/pre19JLue+Ec23GOr26kiB1dq4GRWabQtkGUY4uU=; b=khXPKgMOUihlUGnrUD+ulPY/5QMQkc1SBYoUquMs5giPhvM0Mfr1g3Eb/RizxsGzdQ JTGqv2jhbg3HSD5F7PqLER+AiGr3qfED4mohneZhxpvibM+i8MstLhoO3GxMwNbEMT+f KZZ6cKpCABSZH7mQAGtJxPpNEXL/MWiBQrQP8NW2XZHtpPJswc5a+5RBHh3PN3iW52pQ LUcLiId8jM1en92fy6hn/ujIkc4R406wosiVe2pJQfQ529fMf1EPSIHaFnVQvDJrFguE aKdswpeVoMdpRnmsnBCmqkpcbYa6sf+8FzQhCwsQZyWTzBbf31U8aaenu1eO793nbZ1B bcgg== X-Gm-Message-State: APjAAAVgG1cQJtQrCZ3mDBgQ/7OKeggrz3pIhH6IE6gbgrgSoOMn/2S7 aaUJsY++s5USeAPNQUOQwMU= X-Google-Smtp-Source: APXvYqyGorOOyBrUZPCC8O5eeADmR+dZEkPrxfMj4ju3JxlLHGEzHjAWK1dQ8SNgoxnYksepkgXlOw== X-Received: by 2002:a7b:cf39:: with SMTP id m25mr858657wmg.146.1581368423518; Mon, 10 Feb 2020 13:00:23 -0800 (PST) Received: from localhost.example.com ([31.7.242.222]) by smtp.gmail.com with ESMTPSA id w19sm664344wmc.22.2020.02.10.13.00.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Feb 2020 13:00:23 -0800 (PST) From: Tino Calancha To: "Tassilo Horn" Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> <87ftfiyye1.fsf@gmail.com> <87d0amyxpt.fsf@gmail.com> Date: Mon, 10 Feb 2020 22:00:21 +0100 In-Reply-To: <87d0amyxpt.fsf@gmail.com> (Tino Calancha's message of "Mon, 10 Feb 2020 21:49:18 +0100") Message-ID: <87a75qyx7e.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, Eli Zaretskii , michael.albinus@gmx.de, larsi@gnus.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Tino Calancha writes: >> I have run the testsuite without surprises. > Well, actually there was a surprise, but who don't like surprises after > all! Well, I must recognize I am one of those guys who doesn't like surprises. It seems `when-let' became very popular these days. Here is the updated patch. It takes in account all usages of `when-let' once dropped the cookie. --8<-----------------------------cut here---------------start------------->8--- commit 0c8d7c5312ce167d6123a768c6fe00a2b07288b4 Author: Constantino Calancha Date: Mon Feb 10 21:56:53 2020 +0100 Do not require subr-x at run time Move back `replace-region-contents' to subr.el according with the convention for subr-x (Bug#39546). * lisp/subr-x.el (replace-region-contents): Delete it. (when-let): Delete autoload cookie. * calendar/time-date.el * net/net-utils.el * net/nsm.el * lisp/dired-x.el * lisp/emacs-lisp/edebug.el * lisp/gnus/gnus-sum.el * lisp/gnus/mml.el * lisp/image/image-converter.el * lisp/mail/emacsbug.el * lisp/image/exif.el * net/tramp-compat.el * lisp/net/mailcap.el * lisp/net/tramp-adb.el * lisp/net/tramp-cmds.el * lisp/net/tramp-gvfs.el * lisp/net/tramp-rclone.el * lisp/net/tramp-sh.el * lisp/net/tramp-smb.el * lisp/net/tramp-sudoedit.el * lisp/net/tramp.el: Require subr-x at compile time. * lisp/replace.el (replace-region-contents): Move it from subr-x.el. * lisp/emacs-lisp/json.el: Do not require subr-x since now `replace-region-contents' is loaded at start up. diff --git a/lisp/calendar/time-date.el b/lisp/calendar/time-date.el index e2402de801..b4b13037bf 100644 --- a/lisp/calendar/time-date.el +++ b/lisp/calendar/time-date.el @@ -37,7 +37,7 @@ ;;; Code: (require 'cl-lib) -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (defmacro with-decoded-time-value (varlist &rest body) "Decode a time value and bind it according to VARLIST, then eval BODY. diff --git a/lisp/dired-x.el b/lisp/dired-x.el index 623a1dd325..73029a0095 100644 --- a/lisp/dired-x.el +++ b/lisp/dired-x.el @@ -43,6 +43,7 @@ ;; This is a no-op if dired-x is being loaded via `dired-load-hook', ;; but maybe not if a dired-x function is being autoloaded. (require 'dired) +(eval-when-compile (require 'subr-x)) ;;; User-defined variables. diff --git a/lisp/emacs-lisp/edebug.el b/lisp/emacs-lisp/edebug.el index 85cc8c8e7a..5a5a79488f 100644 --- a/lisp/emacs-lisp/edebug.el +++ b/lisp/emacs-lisp/edebug.el @@ -55,7 +55,9 @@ (require 'backtrace) (require 'macroexp) (require 'cl-lib) -(eval-when-compile (require 'pcase)) +(eval-when-compile + (require 'pcase) + (require 'subr-x) ;;; Options diff --git a/lisp/emacs-lisp/subr-x.el b/lisp/emacs-lisp/subr-x.el index 044c9aada0..2c1415ab2a 100644 --- a/lisp/emacs-lisp/subr-x.el +++ b/lisp/emacs-lisp/subr-x.el @@ -182,7 +182,6 @@ if-let (setq spec (list spec))) (list 'if-let* spec then (macroexp-progn else))) -;;;###autoload (defmacro when-let (spec &rest body) "Bind variables according to SPEC and conditionally evaluate BODY. Evaluate each binding in turn, stopping if a binding value is nil. @@ -254,34 +253,6 @@ string-remove-suffix (substring string 0 (- (length string) (length suffix))) string)) -(defun replace-region-contents (beg end replace-fn - &optional max-secs max-costs) - "Replace the region between BEG and END using REPLACE-FN. -REPLACE-FN runs on the current buffer narrowed to the region. It -should return either a string or a buffer replacing the region. - -The replacement is performed using `replace-buffer-contents' -which also describes the MAX-SECS and MAX-COSTS arguments and the -return value. - -Note: If the replacement is a string, it'll be placed in a -temporary buffer so that `replace-buffer-contents' can operate on -it. Therefore, if you already have the replacement in a buffer, -it makes no sense to convert it to a string using -`buffer-substring' or similar." - (save-excursion - (save-restriction - (narrow-to-region beg end) - (goto-char (point-min)) - (let ((repl (funcall replace-fn))) - (if (bufferp repl) - (replace-buffer-contents repl max-secs max-costs) - (let ((source-buffer (current-buffer))) - (with-temp-buffer - (insert repl) - (let ((tmp-buffer (current-buffer))) - (set-buffer source-buffer) - (replace-buffer-contents tmp-buffer max-secs max-costs))))))))) (provide 'subr-x) diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index a47e657623..bd865ca9b0 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el @@ -25,6 +25,7 @@ ;;; Code: (require 'cl-lib) +(eval-when-compile (require 'subr-x)) (defvar tool-bar-mode) (defvar gnus-category-predicate-alist) diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el index cdd8f3d3a5..903c3ff7ec 100644 --- a/lisp/gnus/mml.el +++ b/lisp/gnus/mml.el @@ -27,9 +27,11 @@ (require 'mm-encode) (require 'mm-decode) (require 'mml-sec) -(eval-when-compile (require 'cl-lib)) -(eval-when-compile (require 'url)) -(eval-when-compile (require 'gnus-util)) +(eval-when-compile + (require 'cl-lib) + (require 'url) + (require 'gnus-util) + (require 'subr-x)) (autoload 'message-make-message-id "message") (declare-function gnus-setup-posting-charset "gnus-msg" (group)) diff --git a/lisp/image/exif.el b/lisp/image/exif.el index 642bc58321..27ad616146 100644 --- a/lisp/image/exif.el +++ b/lisp/image/exif.el @@ -62,6 +62,7 @@ ;;; Code: (require 'cl-lib) +(eval-when-compile (require 'subr-x)) (defvar exif-tag-alist '((11 processing-software) diff --git a/lisp/image/image-converter.el b/lisp/image/image-converter.el index 0488a13d41..33a8903e94 100644 --- a/lisp/image/image-converter.el +++ b/lisp/image/image-converter.el @@ -27,7 +27,9 @@ ;;; Code: (require 'cl-generic) -(eval-when-compile (require 'cl-lib)) +(eval-when-compile + (require 'cl-lib) + (require 'subr-x)) (defcustom image-converter nil "Type of the external image converter to use. diff --git a/lisp/json.el b/lisp/json.el index 18d7fda882..e31928e825 100644 --- a/lisp/json.el +++ b/lisp/json.el @@ -55,7 +55,6 @@ ;;; Code: (require 'map) -(require 'subr-x) ;; Parameters diff --git a/lisp/mail/emacsbug.el b/lisp/mail/emacsbug.el index 7f3dc4454a..3aea5aae8a 100644 --- a/lisp/mail/emacsbug.el +++ b/lisp/mail/emacsbug.el @@ -34,6 +34,7 @@ (require 'sendmail) (require 'message) +(eval-when-compile (require 'subr-x)) (defgroup emacsbug nil "Sending Emacs bug reports." diff --git a/lisp/net/mailcap.el b/lisp/net/mailcap.el index 5fe5b4d3a5..75c91946e4 100644 --- a/lisp/net/mailcap.el +++ b/lisp/net/mailcap.el @@ -29,6 +29,7 @@ ;;; Code: +(eval-when-compile (require 'subr-x)) (autoload 'mail-header-parse-content-type "mail-parse") (defgroup mailcap nil diff --git a/lisp/net/net-utils.el b/lisp/net/net-utils.el index ef3651b033..780f34b028 100644 --- a/lisp/net/net-utils.el +++ b/lisp/net/net-utils.el @@ -44,7 +44,7 @@ ;; days is for /sbin to be a symlink to /usr/sbin, but we still need to ;; search both for older systems. -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (require 'cl-lib) (defun net-utils--executable-find-sbin (command) diff --git a/lisp/net/nsm.el b/lisp/net/nsm.el index 2d36c5e257..f85529f726 100644 --- a/lisp/net/nsm.el +++ b/lisp/net/nsm.el @@ -26,7 +26,7 @@ (require 'cl-lib) (require 'rmc) ; read-multiple-choice -(require 'subr-x) +(eval-when-compile (require 'subr-x)) (require 'seq) (require 'map) diff --git a/lisp/net/tramp-adb.el b/lisp/net/tramp-adb.el index aa7fe147c2..60c46f1224 100644 --- a/lisp/net/tramp-adb.el +++ b/lisp/net/tramp-adb.el @@ -33,6 +33,7 @@ ;;; Code: +(eval-when-compile (require 'subr-x)) (require 'tramp) ;;;###tramp-autoload diff --git a/lisp/net/tramp-cmds.el b/lisp/net/tramp-cmds.el index b4dca2321c..871c215e87 100644 --- a/lisp/net/tramp-cmds.el +++ b/lisp/net/tramp-cmds.el @@ -29,6 +29,7 @@ ;;; Code: (require 'tramp) +(eval-when-compile (require 'subr-x)) ;; Pacify byte-compiler. (declare-function mml-mode "mml") diff --git a/lisp/net/tramp-compat.el b/lisp/net/tramp-compat.el index 87bcd08b85..8f74683dee 100644 --- a/lisp/net/tramp-compat.el +++ b/lisp/net/tramp-compat.el @@ -39,7 +39,7 @@ tramp-unload-file-name-handlers (require 'ls-lisp) ;; Due to `tramp-handle-insert-directory'. (require 'parse-time) (require 'shell) -(require 'subr-x) +(eval-when-compile (require 'subr-x)) ;; `temporary-file-directory' as function is introduced with Emacs 26.1. (declare-function tramp-handle-temporary-file-directory "tramp") diff --git a/lisp/net/tramp-gvfs.el b/lisp/net/tramp-gvfs.el index 0d800cb42b..5b037fb94b 100644 --- a/lisp/net/tramp-gvfs.el +++ b/lisp/net/tramp-gvfs.el @@ -102,6 +102,7 @@ (declare-function dbus-get-unique-name "dbusbind.c") (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) (require 'dbus) (require 'url-parse) diff --git a/lisp/net/tramp-rclone.el b/lisp/net/tramp-rclone.el index 445098a5bc..b7c99829ed 100644 --- a/lisp/net/tramp-rclone.el +++ b/lisp/net/tramp-rclone.el @@ -36,6 +36,7 @@ ;;; Code: (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) ;;;###tramp-autoload diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 5a3abc31ea..0c5bc72deb 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -32,6 +32,7 @@ ;;; Code: (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) (declare-function dired-remove-file "dired-aux") diff --git a/lisp/net/tramp-smb.el b/lisp/net/tramp-smb.el index f02be394a7..43e775b921 100644 --- a/lisp/net/tramp-smb.el +++ b/lisp/net/tramp-smb.el @@ -28,6 +28,7 @@ ;;; Code: (eval-when-compile (require 'cl-lib)) +(eval-when-compile (require 'subr-x)) (require 'tramp) ;; Define SMB method ... diff --git a/lisp/net/tramp-sudoedit.el b/lisp/net/tramp-sudoedit.el index f258ad6b93..6ea52bedf8 100644 --- a/lisp/net/tramp-sudoedit.el +++ b/lisp/net/tramp-sudoedit.el @@ -34,6 +34,7 @@ ;;; Code: +(eval-when-compile (require 'subr-x)) (require 'tramp) ;;;###tramp-autoload diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 19d36c3a97..0783eda09e 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -60,6 +60,7 @@ (require 'tramp-compat) (require 'tramp-integration) (require 'trampver) +(eval-when-compile (require 'subr-x)) ;; Pacify byte-compiler. (require 'cl-lib) diff --git a/lisp/replace.el b/lisp/replace.el index a0b050637e..74c54a0b80 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -743,6 +743,35 @@ replace-regexp (if (use-region-p) (region-noncontiguous-p))))) (perform-replace regexp to-string nil t delimited nil nil start end backward region-noncontiguous-p)) +(defun replace-region-contents (beg end replace-fn + &optional max-secs max-costs) + "Replace the region between BEG and END using REPLACE-FN. +REPLACE-FN runs on the current buffer narrowed to the region. It +should return either a string or a buffer replacing the region. + +The replacement is performed using `replace-buffer-contents' +which also describes the MAX-SECS and MAX-COSTS arguments and the +return value. + +Note: If the replacement is a string, it'll be placed in a +temporary buffer so that `replace-buffer-contents' can operate on +it. Therefore, if you already have the replacement in a buffer, +it makes no sense to convert it to a string using +`buffer-substring' or similar." + (save-excursion + (save-restriction + (narrow-to-region beg end) + (goto-char (point-min)) + (let ((repl (funcall replace-fn))) + (if (bufferp repl) + (replace-buffer-contents repl max-secs max-costs) + (let ((source-buffer (current-buffer))) + (with-temp-buffer + (insert repl) + (let ((tmp-buffer (current-buffer))) + (set-buffer source-buffer) + (replace-buffer-contents tmp-buffer max-secs max-costs))))))))) + (defvar regexp-history nil "History list for some commands that read regular expressions. --8<-----------------------------cut here---------------end--------------->8--- From debbugs-submit-bounces@debbugs.gnu.org Fri Feb 14 05:16:30 2020 Received: (at 39546) by debbugs.gnu.org; 14 Feb 2020 10:16:30 +0000 Received: from localhost ([127.0.0.1]:60892 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j2Y1N-00019L-TY for submit@debbugs.gnu.org; Fri, 14 Feb 2020 05:16:30 -0500 Received: from eggs.gnu.org ([209.51.188.92]:46786) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j2Y1M-000198-9G for 39546@debbugs.gnu.org; Fri, 14 Feb 2020 05:16:28 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47536) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j2Y1G-0007xG-Uu; Fri, 14 Feb 2020 05:16:22 -0500 Received: from [176.228.60.248] (port=3178 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1j2Y1F-0000ai-P7; Fri, 14 Feb 2020 05:16:22 -0500 Date: Fri, 14 Feb 2020 12:16:26 +0200 Message-Id: <8336bdpj7p.fsf@gnu.org> From: Eli Zaretskii To: Tino Calancha In-reply-to: <87a75qyx7e.fsf@gmail.com> (message from Tino Calancha on Mon, 10 Feb 2020 22:00:21 +0100) Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> <87ftfiyye1.fsf@gmail.com> <87d0amyxpt.fsf@gmail.com> <87a75qyx7e.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, larsi@gnus.org, michael.albinus@gmx.de, tsdh@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > From: Tino Calancha > Cc: 39546@debbugs.gnu.org, Eli Zaretskii , > michael.albinus@gmx.de, larsi@gnus.org > Date: Mon, 10 Feb 2020 22:00:21 +0100 > > Tino Calancha writes: > > >> I have run the testsuite without surprises. > > Well, actually there was a surprise, but who don't like surprises after > > all! > Well, I must recognize I am one of those guys who doesn't like > surprises. It seems `when-let' became very popular these days. > > Here is the updated patch. It takes in account all usages of `when-let' > once dropped the cookie. Thanks. Are we talking about doing these changes on master? Because I think such wide-sweeping changes that aren't bugfixes are not really appropriate for the release branch. If you want to move replace-region-contents to replace.el on emacs-27, I agree, but all the rest should go to master, I think. From debbugs-submit-bounces@debbugs.gnu.org Wed Feb 19 08:41:42 2020 Received: (at 39546) by debbugs.gnu.org; 19 Feb 2020 13:41:42 +0000 Received: from localhost ([127.0.0.1]:41775 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j4Pbi-0007iR-9S for submit@debbugs.gnu.org; Wed, 19 Feb 2020 08:41:42 -0500 Received: from quimby.gnus.org ([95.216.78.240]:60366) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j4Pbg-0007iE-Ui for 39546@debbugs.gnu.org; Wed, 19 Feb 2020 08:41:41 -0500 Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1j4PbX-0006Zh-V6; Wed, 19 Feb 2020 14:41:34 +0100 From: Lars Ingebrigtsen To: Tino Calancha Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> <87ftfiyye1.fsf@gmail.com> <87d0amyxpt.fsf@gmail.com> <87a75qyx7e.fsf@gmail.com> Date: Wed, 19 Feb 2020 14:41:31 +0100 In-Reply-To: <87a75qyx7e.fsf@gmail.com> (Tino Calancha's message of "Mon, 10 Feb 2020 22:00:21 +0100") Message-ID: <87pnea8zjo.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Tino Calancha writes: > -; ; ; ###autoload > (defmacro when-let (spec &rest body) > "Bind variables according to SPEC and conditionally evaluate BODY. Sorry; I haven't been following this thread closely, but I don't think this is a good idea. It means putting Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [URIs: ingebrigtsen.no] -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, Eli Zaretskii , michael.albinus@gmx.de, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Tino Calancha writes: > -;;;###autoload > (defmacro when-let (spec &rest body) > "Bind variables according to SPEC and conditionally evaluate BODY. Sorry; I haven't been following this thread closely, but I don't think this is a good idea. It means putting +(eval-when-compile (require 'subr-x)) in more and more files, for no particularly good reason that I can see? What's the reason for removing this autoload? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sat Aug 08 10:06:24 2020 Received: (at 39546) by debbugs.gnu.org; 8 Aug 2020 14:06:25 +0000 Received: from localhost ([127.0.0.1]:59405 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k4PUO-0007Br-NA for submit@debbugs.gnu.org; Sat, 08 Aug 2020 10:06:24 -0400 Received: from quimby.gnus.org ([95.216.78.240]:52430) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k4PUN-0007Bb-57 for 39546@debbugs.gnu.org; Sat, 08 Aug 2020 10:06:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=kt6J0RXg4rydqLcdKHiKZ6Vir/EFjoUNUxU4v4ifZOA=; b=Du6WT76Xyk69LJt9NuwtgokzqJ TxYy0RrVDIQixF8IFAFfig+irMSFbgN4jU+SC5vY7w4KJd+MDTvYGK8zamsP1XvcCsR2bnB8hV+AL n6mPit9H2GjWl7Uq5/iMLqHVq8VVLA7KwrynrPPx8l8SmZudeuYvjsknPttQ9hiIFaw8=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k4PUD-0005Ge-IG; Sat, 08 Aug 2020 16:06:16 +0200 From: Lars Ingebrigtsen To: Tino Calancha Subject: Re: bug#39546: 28.0.50; Do not require subr-x at run time References: <87k14uwnjl.fsf@gmail.com> <831rr2cvci.fsf@gnu.org> <83r1z2bau6.fsf@gnu.org> <57dc180c-4b60-462c-88c2-9a6f97c191df@beta.fastmail.com> <87ftfiyye1.fsf@gmail.com> <87d0amyxpt.fsf@gmail.com> <87a75qyx7e.fsf@gmail.com> <87pnea8zjo.fsf@gnus.org> Date: Sat, 08 Aug 2020 16:06:12 +0200 In-Reply-To: <87pnea8zjo.fsf@gnus.org> (Lars Ingebrigtsen's message of "Wed, 19 Feb 2020 14:41:31 +0100") Message-ID: <87zh75xmej.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Lars Ingebrigtsen writes: > Tino Calancha writes: > >> -;;;###autoload >> (defmacro when-let (spec &rest body) >> "Bind variables according to SPEC and conditionally evaluate BODY. > > Sorry; I haven' [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 39546 Cc: 39546@debbugs.gnu.org, Eli Zaretskii , michael.albinus@gmx.de, Tassilo Horn X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Lars Ingebrigtsen writes: > Tino Calancha writes: > >> -;;;###autoload >> (defmacro when-let (spec &rest body) >> "Bind variables according to SPEC and conditionally evaluate BODY. > > Sorry; I haven't been following this thread closely, but I don't think > this is a good idea. It means putting > > +(eval-when-compile (require 'subr-x)) > > in more and more files, for no particularly good reason that I can see? > > What's the reason for removing this autoload? I think the conclusion was (in a discussion in a different bug report, if I remember correctly) that it's fine to ;;;###autoload when-let, and it's also fine to require subr-x at run time (i.e., it's not just macros and defsubsts). So I'm closing this bug report. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sat Aug 08 10:06:29 2020 Received: (at control) by debbugs.gnu.org; 8 Aug 2020 14:06:29 +0000 Received: from localhost ([127.0.0.1]:59408 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k4PUS-0007C9-Um for submit@debbugs.gnu.org; Sat, 08 Aug 2020 10:06:29 -0400 Received: from quimby.gnus.org ([95.216.78.240]:52444) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k4PUS-0007Bj-2t for control@debbugs.gnu.org; Sat, 08 Aug 2020 10:06:28 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=6kLDhfNpmCQXD3u4OiaBGCXxq9GI5casQe+CbifoYw0=; b=IHGQJCULHJRQrUju2DuRTFmUY4 09wSGlkVsbxciKDFp2xvqQ53i7ueV+P5U58Nm/M0NQ5jMA7GHgBp7d7pRcDdubyD3BVMeSIfwawYB zTZMBjXv+dDKmXr0G3GjtUb8pYnnZ6fxNoHiFYuWUq6aGnXHDbLUE1XP0vVmDV9SXPwM=; Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=xo) by quimby with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k4PUK-0005Gm-Ef for control@debbugs.gnu.org; Sat, 08 Aug 2020 16:06:22 +0200 Date: Sat, 08 Aug 2020 16:06:19 +0200 Message-Id: <87y2mpxmec.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #39546 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: tags 39546 wontfix close 39546 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 39546 wontfix close 39546 quit From unknown Fri Sep 12 08:42:23 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 06 Sep 2020 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator