From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ruijie Yu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#62767: 29.0.90; [PATCH] *lisp/emacs-lisp/package.el: set variables after info package Date: Mon, 17 Apr 2023 14:59:00 +0800 Message-ID: References: <1181651021.466162.1581309285621.ref@mail.yahoo.com> <1181651021.466162.1581309285621@mail.yahoo.com> <87sfd2ns6d.fsf@posteo.net> <833551ecb2.fsf@gnu.org> <87ttxh4e9i.fsf@posteo.net> Reply-To: Ruijie Yu Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14684"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.9.22; emacs 30.0.50 Cc: 62767@debbugs.gnu.org, sunlin7@yahoo.com, eliz@gnu.org, philipk@posteo.net To: Ruijie Yu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Apr 17 09:00:20 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1poIqZ-0003dY-Nw for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 17 Apr 2023 09:00:19 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1poIqO-0001qn-L4; Mon, 17 Apr 2023 03:00:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1poIqK-0001pq-FV for bug-gnu-emacs@gnu.org; Mon, 17 Apr 2023 03:00:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1poIqK-0000uu-5H for bug-gnu-emacs@gnu.org; Mon, 17 Apr 2023 03:00:04 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1poIqI-0004Dl-IB for bug-gnu-emacs@gnu.org; Mon, 17 Apr 2023 03:00:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ruijie Yu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 17 Apr 2023 07:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62767 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-Cc: 62767@debbugs.gnu.org, lin Sun , Eli Zaretskii , Philip Kaludercic , bug-gnu-emacs@gnu.org Original-Received: via spool by 62767-submit@debbugs.gnu.org id=B62767.168171480116188 (code B ref 62767); Mon, 17 Apr 2023 07:00:02 +0000 Original-Received: (at 62767) by debbugs.gnu.org; 17 Apr 2023 07:00:01 +0000 Original-Received: from localhost ([127.0.0.1]:52983 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1poIqG-0004D2-W2 for submit@debbugs.gnu.org; Mon, 17 Apr 2023 03:00:01 -0400 Original-Received: from netyu.xyz ([152.44.41.246]:41042 helo=mail.netyu.xyz) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1poIqF-0004Cs-13 for 62767@debbugs.gnu.org; Mon, 17 Apr 2023 02:59:59 -0400 Original-Received: from fw.net.yu.netyu.xyz ( [222.248.4.98]) by netyu.xyz (OpenSMTPD) with ESMTPSA id 74fa5049 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Mon, 17 Apr 2023 06:59:58 +0000 (UTC) In-reply-to: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:260173 Archived-At: Ruijie Yu writes: > lin Sun via "Bug reports for GNU Emacs, the Swiss army knife of text editors" writes: > >> (let ((package--quickstart-pkgs ()) >> ;; Pretend we haven't activated anything yet! >> (package-activated-list ()) >> @@ -4472,10 +4471,10 @@ package-quickstart-refresh >> (current-buffer)) >> (let ((info-dirs (butlast Info-directory-list))) >> (when info-dirs >> - (pp `(progn (require 'info) >> - (info-initialize) >> - (setq Info-directory-list >> - (append ',info-dirs Info-directory-list))) >> + (pp `(with-eval-after-load 'info >> + (info-initialize) >> + (setq Info-directory-list >> + (append ',info-dirs Info-directory-list))) >> (current-buffer)))) > > I did some testing, and noticed that `with-eval-after-load' returns nil > to its caller when the feature is not loaded. That is, when `info' is > not already loaded, you are effectively calling (pp nil). This is not > feature-equivalent to the original code, so this might require the > `require' form. Sorry, I misread the code. Please ignore this portion of my previous email. -- Best, RY