From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: none Date: Fri, 30 Jul 2021 17:33:45 -0400 Message-ID: References: <87y29rs48j.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24133"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: emacs-devel To: Troy Hinckley Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Jul 30 23:34:30 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m9a9G-00064E-I4 for ged-emacs-devel@m.gmane-mx.org; Fri, 30 Jul 2021 23:34:30 +0200 Original-Received: from localhost ([::1]:33572 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m9a9F-0002Xh-6e for ged-emacs-devel@m.gmane-mx.org; Fri, 30 Jul 2021 17:34:29 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33146) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m9a8f-0001iY-Le for emacs-devel@gnu.org; Fri, 30 Jul 2021 17:33:53 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:9329) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m9a8d-0008TP-Ag for emacs-devel@gnu.org; Fri, 30 Jul 2021 17:33:52 -0400 Original-Received: from pmg1.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id A121C100221; Fri, 30 Jul 2021 17:33:48 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 1E5BA1001E8; Fri, 30 Jul 2021 17:33:47 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1627680827; bh=VI4Kfoy9mDbaJU66YMS8S/udPYSywqE9B/F7GyKQDVU=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=QSsUo54k/XwjxbP515ICwaNDdsnq9FrQGEx+st4rqT/NolxQ70kd4MUof0JDcsXAZ ZkT9s0+0wWGHPSdA/sUJYlUpb1AQtHp2mNttRuXqzL8Unc0WWuFAUv+UQN5ZbkPENu r79EZSkv6k93uXrMyZAHXlUxv5y9Dne4WsLYTVQCmOlOZq4PYbuD9wX+Q3r378GemH QDptvC1XQjPbwEr5ci+gOsiWzhearuXzUSOG0GqAfX+B+vqpukOfWT4hZWEceMNElL MTk2UjpyvX+2+2niBpC6v6IsjPRbn/fMWgG6XcX7oS54wensHSfehankyr3maMedf6 FmP2XGYtGFesA== Original-Received: from alfajor (unknown [216.154.29.138]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id CC9D0120302; Fri, 30 Jul 2021 17:33:46 -0400 (EDT) In-Reply-To: <87y29rs48j.fsf@gmail.com> (Troy Hinckley's message of "Tue, 27 Jul 2021 17:54:25 -0600") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:271875 Archived-At: Troy Hinckley [2021-07-27 17:54:25] wrote: > Subject: Load order for elisp files > User-agent: mu4e 1.2.0; emacs 28.0.50 > I am trying to better understand the bootstrap process for Emacs and I > have run into a chicken and egg problem. When looking for where the > basic functions are defined, I can see that defmacro and defun are defined in > byte-run.el. However the code needed to evaluate a macro is in > backquote.el. Hmm... no, the code in `backquote.el` is only used to macro expand uses of backquotes (which are commonly used in macro definitions but not in all of them) and `byte-run.el` is indeed careful not to use backquotes, specifically because that would break the bootstrap. IIRC there are cases where we rely on even more subtle details, more specifically, I seem to remember that we have functions whose body uses macros that aren't yet defined when we define the function, and this still works OK because this is done at a stage where macro expansion is still lazy, so the macros in the body of the function are only expanded when the function gets called (or when it gets byte-compiled) both of which "happen" to take place later, when the corresponding macros have been defined. Stefan