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


Message #44 received at 15880 <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 15880 <at> debbugs.gnu.org
Subject: Re: bug#15880: Compute C declarations for DEFSYMs automatically.
Date: Wed, 13 Nov 2013 20:13:33 -0800
Stefan Monnier wrote:
> I mean, can the C compiler
> really presume that symbol_vals[0] won't be changed and constant-fold
> its value at link-time?

I was thinking of something that didn't have a symbol_vals table, like this:

struct Lisp_Symbol symbol_structs[N];
#define Qnil make_lisp_ptr (symbol_structs + 0, Lisp_Symbol)
#define Qt   make_lisp_ptr (symbol_structs + 1, Lisp_Symbol)
...

Qnil, Qt etc. should evaluate to compile-time constants for
any reasonably modern C compiler.




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.