Commit 999e6484 authored by Stefan Monnier's avatar Stefan Monnier
Browse files

(store_symval_forwarding): Delete special read-only

hack for type == -1, since we now use ->constant instead.
(Fkill_local_variable): Don't use XBUFFER if it can be nil.
parent a9b9a780
......@@ -897,10 +897,6 @@ store_symval_forwarding (symbol, valcontents, newval, buf)
int offset = XBUFFER_OBJFWD (valcontents)->offset;
Lisp_Object type;
type = PER_BUFFER_TYPE (offset);
if (XINT (type) == -1)
error ("Variable %s is read-only", SDATA (SYMBOL_NAME (symbol)));
if (! NILP (type) && ! NILP (newval)
&& XTYPE (newval) != XINT (type))
buffer_slot_type_mismatch (offset);
......@@ -1616,10 +1612,11 @@ From now on the default value will apply in this buffer. Return VARIABLE. */)
loaded, recompute its value. We have to do it now, or else
forwarded objects won't work right. */
{
Lisp_Object *pvalbuf;
Lisp_Object *pvalbuf, buf;
valcontents = SYMBOL_VALUE (variable);
pvalbuf = &XBUFFER_LOCAL_VALUE (valcontents)->buffer;
if (current_buffer == XBUFFER (*pvalbuf))
XSETBUFFER (buf, current_buffer);
if (EQ (buf, *pvalbuf))
{
*pvalbuf = Qnil;
XBUFFER_LOCAL_VALUE (valcontents)->found_for_buffer = 0;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment