all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Konstantin Kharlamov <Hi-Angel@yandex.ru>
To: emacs-devel@gnu.org
Subject: How does Emacs load a non-existent .el file?
Date: Fri, 01 Mar 2024 13:52:30 +0300	[thread overview]
Message-ID: <0036123ac52383e6a4dc7bc3d76ec2941168b011.camel@yandex.ru> (raw)

I was just looking whether it's too hard to add an option for reading
from stdin (a very requested feature¹). 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-stdin-on-start



             reply	other threads:[~2024-03-01 10:52 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-01 10:52 Konstantin Kharlamov [this message]
2024-03-01 12:22 ` How does Emacs load a non-existent .el file? Eli Zaretskii
2024-03-01 13:30   ` Konstantin Kharlamov
2024-03-01 13:45     ` Eli Zaretskii
2024-03-01 14:15       ` Konstantin Kharlamov
2024-03-01 16:41         ` Eli Zaretskii
2024-03-01 17:53     ` Andreas Schwab
2024-03-01 18:36       ` Konstantin Kharlamov
2024-03-01 20:48         ` Andreas Schwab
2024-03-01 20:57           ` Konstantin Kharlamov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0036123ac52383e6a4dc7bc3d76ec2941168b011.camel@yandex.ru \
    --to=hi-angel@yandex.ru \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.