unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* source-directory, installed Emacs, and C source
@ 2023-10-24 14:31 sbaugh
  2023-10-24 14:47 ` Eli Zaretskii
                   ` (2 more replies)
  0 siblings, 3 replies; 28+ messages in thread
From: sbaugh @ 2023-10-24 14:31 UTC (permalink / raw)
  To: emacs-devel


When Emacs is installed, it remembers the absolute file name of its
source code in source-directory.  And this is used to jump to C function
definitions.

This means if a user installs Emacs out of a Git repository and then the
user updates that Git repository, Emacs will jump to newer C
function definitions.  Namely, Emacs will jump to whatever's currently
in the Git repository rather than what actually was used to compile
Emacs.  (Thank you Eli for pointing this out.)

I see two mutually exclusive interpretations here:

- Jumping to a newer function definition is a problem.

  So we shouldn't be doing it for C.  We can do that by having Emacs
  forget the original source-directory when it's installed.  Probably
  also we should support installing C source files along with Emacs, to
  make up for forgetting source-directory.

  This would be a great improvement for users who don't keep
  source-directory around (since there's now an easy way to install C
  source along with Emacs), and a minor improvement for users that do
  keep source-directory around (since the C function definitions will
  now always match what's used to build Emacs)

- Jumping to a newer function definition is not a problem.

  So we can do it for Lisp too.  We can do that by having Emacs jump to
  Lisp source files from source-directory, too, if they exist.
  (Possibly as an option off by default, if people would prefer that)

  This would be a great improvement for users who keep source-directory
  around (since now Emacs jumps straight to your source repo, allowing
  easy modifications, and also you can skip installing Lisp source files
  with Emacs) and status quo for users that don't keep source-directory
  around.

Thoughts?

I'm interested in implementing one of these two options, since I want to
be able to reliably jump to function definitions from an installed
Emacs.  I don't care which of the two we go with.




^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~2023-10-26  4:57 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-24 14:31 source-directory, installed Emacs, and C source sbaugh
2023-10-24 14:47 ` Eli Zaretskii
2023-10-24 15:13   ` Spencer Baugh
2023-10-24 16:00     ` Eli Zaretskii
2023-10-24 16:20       ` sbaugh
2023-10-24 18:34         ` Eli Zaretskii
2023-10-25  8:41           ` Manuel Giraud via Emacs development discussions.
2023-10-25 12:43             ` Eli Zaretskii
2023-10-25 13:20               ` Manuel Giraud via Emacs development discussions.
2023-10-25 13:43                 ` sbaugh
2023-10-25 13:59                   ` Eli Zaretskii
2023-10-25 14:29                     ` sbaugh
2023-10-25 16:13                       ` Eli Zaretskii
2023-10-25 18:12                         ` Manuel Giraud via Emacs development discussions.
2023-10-25 18:37                           ` Eli Zaretskii
2023-10-25 19:07                             ` Manuel Giraud via Emacs development discussions.
2023-10-25 16:59                       ` Emanuel Berg
2023-10-24 18:35         ` Emanuel Berg
2023-10-25 17:43         ` chad
2023-10-25 18:32           ` Eli Zaretskii
2023-10-25 20:30             ` chad
2023-10-26  4:57               ` Eli Zaretskii
2023-10-25 18:57           ` Manuel Giraud via Emacs development discussions.
2023-10-24 16:00 ` Manuel Giraud via Emacs development discussions.
2023-10-24 16:04   ` Eli Zaretskii
2023-10-24 18:06   ` Emanuel Berg
2023-10-24 18:48   ` Arsen Arsenović
2023-10-24 18:01 ` Manuel Giraud via Emacs development discussions.

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).