GNU bug report logs - #15880
Compute C declarations for DEFSYMs automatically.

Previous Next

Package: emacs;

Reported by: Paul Eggert <eggert <at> cs.ucla.edu>

Date: Wed, 13 Nov 2013 00:35:02 UTC

Severity: wishlist

Tags: patch

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 15880 <at> debbugs.gnu.org
Subject: bug#15880: Compute C declarations for DEFSYMs automatically.
Date: Wed, 13 Nov 2013 17:32:15 -0800
Stefan Monnier wrote:

> The two variables have the
> same name and same content and are read-only, so the redundancy is harmless.

Hmm, well, I suppose you're right.  Still, the idea of removing the
dependency on DEFSYM-related globals would preclude the potential
optimization of putting these globals into a table at compile-time.
I suppose that part of the issue is that I don't add or remove
DEFSYMs very often, so even aside from the precluded optimization
I'm reluctant to complicate the build system just to save a few
build-time cycles on these rare occasions.

> such that make-docfile finds the "INTERN", infers the Lisp name from the
> C name and writes a "syms.c" file which does little else but initialize
> all those symbols.

I was thinking of something even simpler: no macros at all.
If the C source code mentions an identifier Qfoo_bar, make-docfile
automatically generates the Lisp symbol foo-bar.  To aid transition
we could make DEFSYM a no-op, or we could go through the code and
eliminate all the DEFSYM calls.  (This would all be done after the
current patch is installed, of course.)




This bug report was last modified 10 years and 131 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.