[Top][All Lists]

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

Re: RFM: How to make a buffer-local var in C layer

From: Phillip Lord
Subject: Re: RFM: How to make a buffer-local var in C layer
Date: Tue, 15 Sep 2015 16:27:29 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Stefan Monnier <address@hidden> writes:

> Both are C variables of type Lisp_Object.
> The "V" one contains the value of the variable
> `fontification-functions', while the Q one contains the symbol
> `fontification-functions'.

Ah, yes, okay.

>> Fsetq(Qfontification_functions,Qt)
> BTW, one notable difference (other than performance) between
>     Fset (Qfontification_functions, Qt);
> and
>     Vfontification_functions = Qt;
> is that the former will obey make-variable-buffer-local while the
> latter won't.  So if you want the var to be buffer-local, either use the
> former, or make sure to call Fmake_local_variable explicitly at
> some point.

Okay. Performance is irrelevant here, to be honest, so I've gone for

I've pushed those changes up to my branch now and they appear to be
working. I think that I have all the C support that I need, and I'd
welcome any comments that you have (don't worry about all the commits
and change messages -- I'm planning on squashing before I'd think about
moving to master).

I'll add the emacs-lisp support next, which should be relatively


reply via email to

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