emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Emacs-diffs] trunk r117846: Add macros to allocate temporary Lisp o


From: Paul Eggert
Subject: Re: [Emacs-diffs] trunk r117846: Add macros to allocate temporary Lisp objects with alloca.
Date: Tue, 09 Sep 2014 11:37:13 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.0

Stefan Monnier wrote:
Any chance `alignas' can be used where we create the stack-allocated
object, maybe?

Although I think we could do that, there would be quite a cost in terms of expressiveness. The macro to create the stack-allocated object would have to expand to a declaration of a local variable, which would mean that it could not be a function-like macro scoped_cons (a, b) but instead would have to be a declaration-like macro SCOPED_NAMED_CONS (name, a, b), where NAME would give the name of the newly-allocated struct Lisp_Cons object.

I'm finding it a bit hard to think about all this, by the way, as it the new definitions aren't used anywhere, which makes it hard to see some of the motivation here.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]