From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Konstantin Kharlamov Newsgroups: gmane.emacs.devel Subject: How does Emacs load a non-existent .el file? Date: Fri, 01 Mar 2024 13:52:30 +0300 Message-ID: <0036123ac52383e6a4dc7bc3d76ec2941168b011.camel@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="15897"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Evolution 3.50.4 To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Mar 01 11:53:52 2024 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 1rg0WV-0003lu-NI for ged-emacs-devel@m.gmane-mx.org; Fri, 01 Mar 2024 11:53:51 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rg0Vh-0002jv-A5; Fri, 01 Mar 2024 05:53:02 -0500 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 1rg0VZ-0002gs-AN for emacs-devel@gnu.org; Fri, 01 Mar 2024 05:52:54 -0500 Original-Received: from forward100c.mail.yandex.net ([178.154.239.211]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rg0VS-0003Mk-Vj for emacs-devel@gnu.org; Fri, 01 Mar 2024 05:52:50 -0500 Original-Received: from mail-nwsmtp-smtp-production-main-54.iva.yp-c.yandex.net (mail-nwsmtp-smtp-production-main-54.iva.yp-c.yandex.net [IPv6:2a02:6b8:c0c:2e21:0:640:2d13:0]) by forward100c.mail.yandex.net (Yandex) with ESMTPS id E751960AA8 for ; Fri, 1 Mar 2024 13:52:31 +0300 (MSK) Original-Received: by mail-nwsmtp-smtp-production-main-54.iva.yp-c.yandex.net (smtp/Yandex) with ESMTPSA id UqY6iOL1Ha60-Z9xCd1zG; Fri, 01 Mar 2024 13:52:31 +0300 X-Yandex-Fwd: 1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1709290351; bh=9gtWCxzPaxhcG9XrWsr0vN0o7jQ1gyl1zZNZRz+4bcE=; h=Date:To:From:Subject:Message-ID; b=fpUBWYIMdU64Rd7XQq0nykVBP8VcUN7Ou+OTPMztOsvLbtyoHjmyxpzlqnptf2PNp Jl7RSufSyVkdrPsEL7AcWtliIgCux3yj8iatgiE2p1Qnd1sxwiFSbByDwls68B0i0Z 1RX2kaOoKA+6LDWTShKEst3V4w7tCncmtoCtCeO4= Authentication-Results: mail-nwsmtp-smtp-production-main-54.iva.yp-c.yandex.net; dkim=pass header.i=@yandex.ru Received-SPF: pass client-ip=178.154.239.211; envelope-from=Hi-Angel@yandex.ru; helo=forward100c.mail.yandex.net X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:316655 Archived-At: I was just looking whether it's too hard to add an option for reading from stdin (a very requested feature=C2=B9). Long story short, I presume command line parsing happens in `lisp/startup.el`, function `(command- line-1)`. That's where the weirdness starts. Since it is an ELisp file, I figured to avoid recompiling I can move its `.elc` file out of the way and just do edits to `startup.el` directly. Turned out though, not only Emacs does not notice these edits, it somehow manages to load the file when it does not exist! So e.g. I did a `sudo rm /usr/share/emacs/30.0.50/lisp/startup*`, so no .el or elc files. But starting up `emacs -Q` and asking it `C-h f command-line-1` still results in Emacs answering that such function exists, except the help buffer doesn't have a link to it. I am thoroughly confused. Any idea what's going on here? 1: https://superuser.com/questions/31404/how-to-make-emacs-read-buffer-from-st= din-on-start