Use XCAR, XCDR, and XFLOAT_DATA instead of explicit member access.

This commit is contained in:
Ken Raeburn 1999-09-13 02:23:04 +00:00
parent 926106201f
commit 03699b140e
11 changed files with 295 additions and 295 deletions

View file

@ -591,15 +591,15 @@ word_boundary_p (c1, c2)
if (NILP (category_set2)) if (NILP (category_set2))
return default_result; return default_result;
for (; CONSP (tail); tail = XCONS (tail)->cdr) for (; CONSP (tail); tail = XCDR (tail))
{ {
Lisp_Object elt = XCONS(tail)->car; Lisp_Object elt = XCAR (tail);
if (CONSP (elt) if (CONSP (elt)
&& CATEGORYP (XCONS (elt)->car) && CATEGORYP (XCAR (elt))
&& CATEGORYP (XCONS (elt)->cdr) && CATEGORYP (XCDR (elt))
&& CATEGORY_MEMBER (XFASTINT (XCONS (elt)->car), category_set1) && CATEGORY_MEMBER (XFASTINT (XCAR (elt)), category_set1)
&& CATEGORY_MEMBER (XFASTINT (XCONS (elt)->cdr), category_set2)) && CATEGORY_MEMBER (XFASTINT (XCDR (elt)), category_set2))
return !default_result; return !default_result;
} }
return default_result; return default_result;

View file

@ -1328,7 +1328,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
/* Check map varidity. */ /* Check map varidity. */
if (!CONSP (map)) continue; if (!CONSP (map)) continue;
map = XCONS(map)->cdr; map = XCDR (map);
if (!VECTORP (map)) continue; if (!VECTORP (map)) continue;
size = XVECTOR (map)->size; size = XVECTOR (map)->size;
if (size <= 1) continue; if (size <= 1) continue;
@ -1372,8 +1372,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
} }
else if (CONSP (content)) else if (CONSP (content))
{ {
attrib = XCONS (content)->car; attrib = XCAR (content);
value = XCONS (content)->cdr; value = XCDR (content);
if (!NUMBERP (attrib) || !NUMBERP (value)) if (!NUMBERP (attrib) || !NUMBERP (value))
continue; continue;
reg[RRR] = i; reg[RRR] = i;
@ -1437,7 +1437,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
/* Check map varidity. */ /* Check map varidity. */
if (!CONSP (map)) continue; if (!CONSP (map)) continue;
map = XCONS (map)->cdr; map = XCDR (map);
if (!VECTORP (map)) continue; if (!VECTORP (map)) continue;
size = XVECTOR (map)->size; size = XVECTOR (map)->size;
if (size <= 1) continue; if (size <= 1) continue;
@ -1477,8 +1477,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
} }
else if (CONSP (content)) else if (CONSP (content))
{ {
attrib = XCONS (content)->car; attrib = XCAR (content);
value = XCONS (content)->cdr; value = XCDR (content);
if (!NUMBERP (attrib) || !NUMBERP (value)) if (!NUMBERP (attrib) || !NUMBERP (value))
continue; continue;
reg[RRR] = i; reg[RRR] = i;
@ -1522,7 +1522,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
reg[RRR] = -1; reg[RRR] = -1;
break; break;
} }
map = XCONS(map)->cdr; map = XCDR (map);
if (!VECTORP (map)) if (!VECTORP (map))
{ {
reg[RRR] = -1; reg[RRR] = -1;
@ -1546,8 +1546,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
reg[RRR] = i; reg[RRR] = i;
else if (CONSP (content)) else if (CONSP (content))
{ {
attrib = XCONS (content)->car; attrib = XCAR (content);
value = XCONS (content)->cdr; value = XCDR (content);
if (!NUMBERP (attrib) || !NUMBERP (value)) if (!NUMBERP (attrib) || !NUMBERP (value))
continue; continue;
reg[rrr] = XUINT(value); reg[rrr] = XUINT(value);
@ -1663,8 +1663,8 @@ resolve_symbol_ccl_program (ccl)
if (INTEGERP (contents)) if (INTEGERP (contents))
continue; continue;
else if (CONSP (contents) else if (CONSP (contents)
&& SYMBOLP (XCONS (contents)->car) && SYMBOLP (XCAR (contents))
&& SYMBOLP (XCONS (contents)->cdr)) && SYMBOLP (XCDR (contents)))
{ {
/* This is the new style for embedding symbols. The form is /* This is the new style for embedding symbols. The form is
(SYMBOL . PROPERTY). (get SYMBOL PROPERTY) should give (SYMBOL . PROPERTY). (get SYMBOL PROPERTY) should give
@ -1673,7 +1673,7 @@ resolve_symbol_ccl_program (ccl)
if (EQ (result, ccl)) if (EQ (result, ccl))
result = Fcopy_sequence (ccl); result = Fcopy_sequence (ccl);
val = Fget (XCONS (contents)->car, XCONS (contents)->cdr); val = Fget (XCAR (contents), XCDR (contents));
if (NATNUMP (val)) if (NATNUMP (val))
XVECTOR (result)->contents[i] = val; XVECTOR (result)->contents[i] = val;
else else
@ -2038,10 +2038,10 @@ Return index number of the registered map.")
if (!CONSP (slot)) if (!CONSP (slot))
break; break;
if (EQ (symbol, XCONS (slot)->car)) if (EQ (symbol, XCAR (slot)))
{ {
index = make_number (i); index = make_number (i);
XCONS (slot)->cdr = map; XCDR (slot) = map;
Fput (symbol, Qcode_conversion_map, map); Fput (symbol, Qcode_conversion_map, map);
Fput (symbol, Qcode_conversion_map_id, index); Fput (symbol, Qcode_conversion_map_id, index);
return index; return index;

View file

@ -2974,9 +2974,9 @@ setup_coding_system (coding_system, coding)
bzero (coding->safe_charsets, MAX_CHARSET + 1); bzero (coding->safe_charsets, MAX_CHARSET + 1);
while (CONSP (val)) while (CONSP (val))
{ {
if ((i = get_charset_id (XCONS (val)->car)) >= 0) if ((i = get_charset_id (XCAR (val))) >= 0)
coding->safe_charsets[i] = 1; coding->safe_charsets[i] = 1;
val = XCONS (val)->cdr; val = XCDR (val);
} }
} }
@ -3042,12 +3042,12 @@ setup_coding_system (coding_system, coding)
val = Vcharset_revision_alist; val = Vcharset_revision_alist;
while (CONSP (val)) while (CONSP (val))
{ {
charset = get_charset_id (Fcar_safe (XCONS (val)->car)); charset = get_charset_id (Fcar_safe (XCAR (val)));
if (charset >= 0 if (charset >= 0
&& (temp = Fcdr_safe (XCONS (val)->car), INTEGERP (temp)) && (temp = Fcdr_safe (XCAR (val)), INTEGERP (temp))
&& (i = XINT (temp), (i >= 0 && (i + '@') < 128))) && (i = XINT (temp), (i >= 0 && (i + '@') < 128)))
CODING_SPEC_ISO_REVISION_NUMBER (coding, charset) = i; CODING_SPEC_ISO_REVISION_NUMBER (coding, charset) = i;
val = XCONS (val)->cdr; val = XCDR (val);
} }
/* Checks FLAGS[REG] (REG = 0, 1, 2 3) and decide designations. /* Checks FLAGS[REG] (REG = 0, 1, 2 3) and decide designations.
@ -3084,28 +3084,28 @@ setup_coding_system (coding_system, coding)
tail = flags[i]; tail = flags[i];
coding->flags |= CODING_FLAG_ISO_DESIGNATION; coding->flags |= CODING_FLAG_ISO_DESIGNATION;
if (INTEGERP (XCONS (tail)->car) if (INTEGERP (XCAR (tail))
&& (charset = XINT (XCONS (tail)->car), && (charset = XINT (XCAR (tail)),
CHARSET_VALID_P (charset)) CHARSET_VALID_P (charset))
|| (charset = get_charset_id (XCONS (tail)->car)) >= 0) || (charset = get_charset_id (XCAR (tail))) >= 0)
{ {
CODING_SPEC_ISO_INITIAL_DESIGNATION (coding, i) = charset; CODING_SPEC_ISO_INITIAL_DESIGNATION (coding, i) = charset;
CODING_SPEC_ISO_REQUESTED_DESIGNATION (coding, charset) =i; CODING_SPEC_ISO_REQUESTED_DESIGNATION (coding, charset) =i;
} }
else else
CODING_SPEC_ISO_INITIAL_DESIGNATION (coding, i) = -1; CODING_SPEC_ISO_INITIAL_DESIGNATION (coding, i) = -1;
tail = XCONS (tail)->cdr; tail = XCDR (tail);
while (CONSP (tail)) while (CONSP (tail))
{ {
if (INTEGERP (XCONS (tail)->car) if (INTEGERP (XCAR (tail))
&& (charset = XINT (XCONS (tail)->car), && (charset = XINT (XCAR (tail)),
CHARSET_VALID_P (charset)) CHARSET_VALID_P (charset))
|| (charset = get_charset_id (XCONS (tail)->car)) >= 0) || (charset = get_charset_id (XCAR (tail))) >= 0)
CODING_SPEC_ISO_REQUESTED_DESIGNATION (coding, charset) CODING_SPEC_ISO_REQUESTED_DESIGNATION (coding, charset)
= i; = i;
else if (EQ (XCONS (tail)->car, Qt)) else if (EQ (XCAR (tail), Qt))
reg_bits |= 1 << i; reg_bits |= 1 << i;
tail = XCONS (tail)->cdr; tail = XCDR (tail);
} }
} }
else else
@ -3168,9 +3168,9 @@ setup_coding_system (coding_system, coding)
val = XVECTOR (coding_spec)->contents[4]; val = XVECTOR (coding_spec)->contents[4];
if (! CONSP (val) if (! CONSP (val)
|| setup_ccl_program (&(coding->spec.ccl.decoder), || setup_ccl_program (&(coding->spec.ccl.decoder),
XCONS (val)->car) < 0 XCAR (val)) < 0
|| setup_ccl_program (&(coding->spec.ccl.encoder), || setup_ccl_program (&(coding->spec.ccl.encoder),
XCONS (val)->cdr) < 0) XCDR (val)) < 0)
goto label_invalid_coding_system; goto label_invalid_coding_system;
bzero (coding->spec.ccl.valid_codes, 256); bzero (coding->spec.ccl.valid_codes, 256);
@ -3179,18 +3179,18 @@ setup_coding_system (coding_system, coding)
{ {
Lisp_Object this; Lisp_Object this;
for (; CONSP (val); val = XCONS (val)->cdr) for (; CONSP (val); val = XCDR (val))
{ {
this = XCONS (val)->car; this = XCAR (val);
if (INTEGERP (this) if (INTEGERP (this)
&& XINT (this) >= 0 && XINT (this) < 256) && XINT (this) >= 0 && XINT (this) < 256)
coding->spec.ccl.valid_codes[XINT (this)] = 1; coding->spec.ccl.valid_codes[XINT (this)] = 1;
else if (CONSP (this) else if (CONSP (this)
&& INTEGERP (XCONS (this)->car) && INTEGERP (XCAR (this))
&& INTEGERP (XCONS (this)->cdr)) && INTEGERP (XCDR (this)))
{ {
int start = XINT (XCONS (this)->car); int start = XINT (XCAR (this));
int end = XINT (XCONS (this)->cdr); int end = XINT (XCDR (this));
if (start >= 0 && start <= end && end < 256) if (start >= 0 && start <= end && end < 256)
while (start <= end) while (start <= end)
@ -4876,13 +4876,13 @@ detect_coding_system (src, src_bytes, highest)
/* At first, gather possible coding systems in VAL. */ /* At first, gather possible coding systems in VAL. */
val = Qnil; val = Qnil;
for (tmp = Vcoding_category_list; !NILP (tmp); tmp = XCONS (tmp)->cdr) for (tmp = Vcoding_category_list; !NILP (tmp); tmp = XCDR (tmp))
{ {
int idx int idx
= XFASTINT (Fget (XCONS (tmp)->car, Qcoding_category_index)); = XFASTINT (Fget (XCAR (tmp), Qcoding_category_index));
if (coding_mask & (1 << idx)) if (coding_mask & (1 << idx))
{ {
val = Fcons (Fsymbol_value (XCONS (tmp)->car), val); val = Fcons (Fsymbol_value (XCAR (tmp)), val);
if (highest) if (highest)
break; break;
} }
@ -4891,18 +4891,18 @@ detect_coding_system (src, src_bytes, highest)
val = Fnreverse (val); val = Fnreverse (val);
/* Then, replace the elements with subsidiary coding systems. */ /* Then, replace the elements with subsidiary coding systems. */
for (tmp = val; !NILP (tmp); tmp = XCONS (tmp)->cdr) for (tmp = val; !NILP (tmp); tmp = XCDR (tmp))
{ {
if (eol_type != CODING_EOL_UNDECIDED if (eol_type != CODING_EOL_UNDECIDED
&& eol_type != CODING_EOL_INCONSISTENT) && eol_type != CODING_EOL_INCONSISTENT)
{ {
Lisp_Object eol; Lisp_Object eol;
eol = Fget (XCONS (tmp)->car, Qeol_type); eol = Fget (XCAR (tmp), Qeol_type);
if (VECTORP (eol)) if (VECTORP (eol))
XCONS (tmp)->car = XVECTOR (eol)->contents[eol_type]; XCAR (tmp) = XVECTOR (eol)->contents[eol_type];
} }
} }
return (highest ? XCONS (val)->car : val); return (highest ? XCAR (val) : val);
} }
DEFUN ("detect-coding-region", Fdetect_coding_region, Sdetect_coding_region, DEFUN ("detect-coding-region", Fdetect_coding_region, Sdetect_coding_region,
@ -5324,18 +5324,18 @@ which is a list of all the arguments given to this function.")
if (NILP (chain)) if (NILP (chain))
return Qnil; return Qnil;
for (; CONSP (chain); chain = XCONS (chain)->cdr) for (; CONSP (chain); chain = XCDR (chain))
{ {
Lisp_Object elt; Lisp_Object elt;
elt = XCONS (chain)->car; elt = XCAR (chain);
if (CONSP (elt) if (CONSP (elt)
&& ((STRINGP (target) && ((STRINGP (target)
&& STRINGP (XCONS (elt)->car) && STRINGP (XCAR (elt))
&& fast_string_match (XCONS (elt)->car, target) >= 0) && fast_string_match (XCAR (elt), target) >= 0)
|| (INTEGERP (target) && EQ (target, XCONS (elt)->car)))) || (INTEGERP (target) && EQ (target, XCAR (elt)))))
{ {
val = XCONS (elt)->cdr; val = XCDR (elt);
/* Here, if VAL is both a valid coding system and a valid /* Here, if VAL is both a valid coding system and a valid
function symbol, we return VAL as a coding system. */ function symbol, we return VAL as a coding system. */
if (CONSP (val)) if (CONSP (val))
@ -5406,13 +5406,13 @@ This function is internal use only.")
while (CONSP (val) && i < CODING_CATEGORY_IDX_MAX) while (CONSP (val) && i < CODING_CATEGORY_IDX_MAX)
{ {
if (! SYMBOLP (XCONS (val)->car)) if (! SYMBOLP (XCAR (val)))
break; break;
idx = XFASTINT (Fget (XCONS (val)->car, Qcoding_category_index)); idx = XFASTINT (Fget (XCAR (val), Qcoding_category_index));
if (idx >= CODING_CATEGORY_IDX_MAX) if (idx >= CODING_CATEGORY_IDX_MAX)
break; break;
coding_priorities[i++] = (1 << idx); coding_priorities[i++] = (1 << idx);
val = XCONS (val)->cdr; val = XCDR (val);
} }
/* If coding-category-list is valid and contains all coding /* If coding-category-list is valid and contains all coding
categories, `i' should be CODING_CATEGORY_IDX_MAX now. If not, categories, `i' should be CODING_CATEGORY_IDX_MAX now. If not,

View file

@ -126,8 +126,8 @@ get_doc_string (filepos, unibyte, definition)
} }
else if (CONSP (filepos)) else if (CONSP (filepos))
{ {
file = XCONS (filepos)->car; file = XCAR (filepos);
position = XINT (XCONS (filepos)->cdr); position = XINT (XCDR (filepos));
if (position < 0) if (position < 0)
position = - position; position = - position;
} }
@ -353,7 +353,7 @@ string is passed through `substitute-command-keys'.")
/* Handle a doc reference--but these never come last /* Handle a doc reference--but these never come last
in the function body, so reject them if they are last. */ in the function body, so reject them if they are last. */
else if ((NATNUMP (tem) || CONSP (tem)) else if ((NATNUMP (tem) || CONSP (tem))
&& ! NILP (XCONS (tem1)->cdr)) && ! NILP (XCDR (tem1)))
doc = get_doc_string (tem, 0, 0); doc = get_doc_string (tem, 0, 0);
else else
return Qnil; return Qnil;
@ -424,15 +424,15 @@ store_function_docstring (fun, offset)
{ {
Lisp_Object tem; Lisp_Object tem;
tem = XCONS (fun)->car; tem = XCAR (fun);
if (EQ (tem, Qlambda) || EQ (tem, Qautoload)) if (EQ (tem, Qlambda) || EQ (tem, Qautoload))
{ {
tem = Fcdr (Fcdr (fun)); tem = Fcdr (Fcdr (fun));
if (CONSP (tem) && INTEGERP (XCONS (tem)->car)) if (CONSP (tem) && INTEGERP (XCAR (tem)))
XSETFASTINT (XCONS (tem)->car, offset); XSETFASTINT (XCAR (tem), offset);
} }
else if (EQ (tem, Qmacro)) else if (EQ (tem, Qmacro))
store_function_docstring (XCONS (fun)->cdr, offset); store_function_docstring (XCDR (fun), offset);
} }
/* Bytecode objects sometimes have slots for it. */ /* Bytecode objects sometimes have slots for it. */

View file

@ -2288,13 +2288,13 @@ save_restriction_restore (data)
register Lisp_Object tem; register Lisp_Object tem;
int obegv, ozv; int obegv, ozv;
buf = XBUFFER (XCONS (data)->car); buf = XBUFFER (XCAR (data));
data = XCONS (data)->cdr; data = XCDR (data);
tem = XCONS (data)->car; tem = XCAR (data);
newhead = XINT (tem); newhead = XINT (tem);
tem = XCONS (data)->cdr; tem = XCDR (data);
newtail = XINT (tem); newtail = XINT (tem);
if (newhead + newtail > BUF_Z (buf) - BUF_BEG (buf)) if (newhead + newtail > BUF_Z (buf) - BUF_BEG (buf))
{ {
@ -2761,7 +2761,7 @@ Use %% to put a single % into the output.")
if (INTEGERP (args[n])) if (INTEGERP (args[n]))
sprintf (p, this_format, XINT (args[n])); sprintf (p, this_format, XINT (args[n]));
else else
sprintf (p, this_format, XFLOAT (args[n])->data); sprintf (p, this_format, XFLOAT_DATA (args[n]));
if (p > buf if (p > buf
&& multibyte && multibyte

View file

@ -322,11 +322,11 @@ CONDITION's value if non-nil is returned from the cond-form.")
val = Feval (Fcar (clause)); val = Feval (Fcar (clause));
if (!NILP (val)) if (!NILP (val))
{ {
if (!EQ (XCONS (clause)->cdr, Qnil)) if (!EQ (XCDR (clause), Qnil))
val = Fprogn (XCONS (clause)->cdr); val = Fprogn (XCDR (clause));
break; break;
} }
args = XCONS (args)->cdr; args = XCDR (args);
} }
UNGCPRO; UNGCPRO;
@ -670,9 +670,9 @@ for the variable is `*'.")
return Qt; return Qt;
/* If it is (STRING . INTEGER), a negative integer means a user variable. */ /* If it is (STRING . INTEGER), a negative integer means a user variable. */
if (CONSP (documentation) if (CONSP (documentation)
&& STRINGP (XCONS (documentation)->car) && STRINGP (XCAR (documentation))
&& INTEGERP (XCONS (documentation)->cdr) && INTEGERP (XCDR (documentation))
&& XINT (XCONS (documentation)->cdr) < 0) && XINT (XCDR (documentation)) < 0)
return Qt; return Qt;
return Qnil; return Qnil;
} }
@ -818,7 +818,7 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
if (!CONSP (form)) if (!CONSP (form))
break; break;
/* Set SYM, give DEF and TEM right values in case SYM is not a symbol. */ /* Set SYM, give DEF and TEM right values in case SYM is not a symbol. */
def = sym = XCONS (form)->car; def = sym = XCAR (form);
tem = Qnil; tem = Qnil;
/* Trace symbols aliases to other symbols /* Trace symbols aliases to other symbols
until we get a symbol that is not an alias. */ until we get a symbol that is not an alias. */
@ -844,7 +844,7 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
if (EQ (def, Qunbound) || !CONSP (def)) if (EQ (def, Qunbound) || !CONSP (def))
/* Not defined or definition not suitable */ /* Not defined or definition not suitable */
break; break;
if (EQ (XCONS (def)->car, Qautoload)) if (EQ (XCAR (def), Qautoload))
{ {
/* Autoloading function: will it be a macro when loaded? */ /* Autoloading function: will it be a macro when loaded? */
tem = Fnth (make_number (4), def); tem = Fnth (make_number (4), def);
@ -860,17 +860,17 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
else else
break; break;
} }
else if (!EQ (XCONS (def)->car, Qmacro)) else if (!EQ (XCAR (def), Qmacro))
break; break;
else expander = XCONS (def)->cdr; else expander = XCDR (def);
} }
else else
{ {
expander = XCONS (tem)->cdr; expander = XCDR (tem);
if (NILP (expander)) if (NILP (expander))
break; break;
} }
form = apply1 (expander, XCONS (form)->cdr); form = apply1 (expander, XCDR (form));
} }
return form; return form;
} }
@ -1062,8 +1062,8 @@ See also the function `signal' for more info.")
tem = Fcar (val); tem = Fcar (val);
if (! (NILP (tem) if (! (NILP (tem)
|| (CONSP (tem) || (CONSP (tem)
&& (SYMBOLP (XCONS (tem)->car) && (SYMBOLP (XCAR (tem))
|| CONSP (XCONS (tem)->car))))) || CONSP (XCAR (tem))))))
error ("Invalid condition handler", tem); error ("Invalid condition handler", tem);
} }
@ -1311,11 +1311,11 @@ wants_debugger (list, conditions)
while (CONSP (conditions)) while (CONSP (conditions))
{ {
Lisp_Object this, tail; Lisp_Object this, tail;
this = XCONS (conditions)->car; this = XCAR (conditions);
for (tail = list; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = list; CONSP (tail); tail = XCDR (tail))
if (EQ (XCONS (tail)->car, this)) if (EQ (XCAR (tail), this))
return 1; return 1;
conditions = XCONS (conditions)->cdr; conditions = XCDR (conditions);
} }
return 0; return 0;
} }
@ -1333,16 +1333,16 @@ skip_debugger (conditions, data)
Lisp_Object error_message; Lisp_Object error_message;
for (tail = Vdebug_ignored_errors; CONSP (tail); for (tail = Vdebug_ignored_errors; CONSP (tail);
tail = XCONS (tail)->cdr) tail = XCDR (tail))
{ {
if (STRINGP (XCONS (tail)->car)) if (STRINGP (XCAR (tail)))
{ {
if (first_string) if (first_string)
{ {
error_message = Ferror_message_string (data); error_message = Ferror_message_string (data);
first_string = 0; first_string = 0;
} }
if (fast_string_match (XCONS (tail)->car, error_message) >= 0) if (fast_string_match (XCAR (tail), error_message) >= 0)
return 1; return 1;
} }
else else
@ -1350,8 +1350,8 @@ skip_debugger (conditions, data)
Lisp_Object contail; Lisp_Object contail;
for (contail = conditions; CONSP (contail); for (contail = conditions; CONSP (contail);
contail = XCONS (contail)->cdr) contail = XCDR (contail))
if (EQ (XCONS (tail)->car, XCONS (contail)->car)) if (EQ (XCAR (tail), XCAR (contail)))
return 1; return 1;
} }
} }
@ -1458,7 +1458,7 @@ find_handler_clause (handlers, conditions, sig, data, debugger_value_ptr)
tem = Fmemq (Fcar (condit), conditions); tem = Fmemq (Fcar (condit), conditions);
if (!NILP (tem)) if (!NILP (tem))
return handler; return handler;
condit = XCONS (condit)->cdr; condit = XCDR (condit);
} }
} }
} }
@ -1599,7 +1599,7 @@ this does nothing and returns nil.")
/* If function is defined and not as an autoload, don't override */ /* If function is defined and not as an autoload, don't override */
if (!EQ (XSYMBOL (function)->function, Qunbound) if (!EQ (XSYMBOL (function)->function, Qunbound)
&& !(CONSP (XSYMBOL (function)->function) && !(CONSP (XSYMBOL (function)->function)
&& EQ (XCONS (XSYMBOL (function)->function)->car, Qautoload))) && EQ (XCAR (XSYMBOL (function)->function), Qautoload)))
return Qnil; return Qnil;
#ifdef NO_ARG_ARRAY #ifdef NO_ARG_ARRAY
@ -1929,7 +1929,7 @@ Thus, (apply '+ 1 2 '(3 4)) returns 10.")
return Ffuncall (nargs - 1, args); return Ffuncall (nargs - 1, args);
else if (numargs == 1) else if (numargs == 1)
{ {
args [nargs - 1] = XCONS (spread_arg)->car; args [nargs - 1] = XCAR (spread_arg);
return Ffuncall (nargs, args); return Ffuncall (nargs, args);
} }
@ -1977,8 +1977,8 @@ Thus, (apply '+ 1 2 '(3 4)) returns 10.")
i = nargs - 1; i = nargs - 1;
while (!NILP (spread_arg)) while (!NILP (spread_arg))
{ {
funcall_args [i++] = XCONS (spread_arg)->car; funcall_args [i++] = XCAR (spread_arg);
spread_arg = XCONS (spread_arg)->cdr; spread_arg = XCDR (spread_arg);
} }
RETURN_UNGCPRO (Ffuncall (gcpro1.nvars, funcall_args)); RETURN_UNGCPRO (Ffuncall (gcpro1.nvars, funcall_args));
@ -2101,7 +2101,7 @@ run_hook_with_args (nargs, args, cond)
if (EQ (val, Qunbound) || NILP (val)) if (EQ (val, Qunbound) || NILP (val))
return ret; return ret;
else if (!CONSP (val) || EQ (XCONS (val)->car, Qlambda)) else if (!CONSP (val) || EQ (XCAR (val), Qlambda))
{ {
args[0] = val; args[0] = val;
return Ffuncall (nargs, args); return Ffuncall (nargs, args);
@ -2115,9 +2115,9 @@ run_hook_with_args (nargs, args, cond)
CONSP (val) && ((cond == to_completion) CONSP (val) && ((cond == to_completion)
|| (cond == until_success ? NILP (ret) || (cond == until_success ? NILP (ret)
: !NILP (ret))); : !NILP (ret)));
val = XCONS (val)->cdr) val = XCDR (val))
{ {
if (EQ (XCONS (val)->car, Qt)) if (EQ (XCAR (val), Qt))
{ {
/* t indicates this hook has a local binding; /* t indicates this hook has a local binding;
it means to run the global binding too. */ it means to run the global binding too. */
@ -2126,9 +2126,9 @@ run_hook_with_args (nargs, args, cond)
CONSP (globals) && ((cond == to_completion) CONSP (globals) && ((cond == to_completion)
|| (cond == until_success ? NILP (ret) || (cond == until_success ? NILP (ret)
: !NILP (ret))); : !NILP (ret)));
globals = XCONS (globals)->cdr) globals = XCDR (globals))
{ {
args[0] = XCONS (globals)->car; args[0] = XCAR (globals);
/* In a global value, t should not occur. If it does, we /* In a global value, t should not occur. If it does, we
must ignore it to avoid an endless loop. */ must ignore it to avoid an endless loop. */
if (!EQ (args[0], Qt)) if (!EQ (args[0], Qt))
@ -2137,7 +2137,7 @@ run_hook_with_args (nargs, args, cond)
} }
else else
{ {
args[0] = XCONS (val)->car; args[0] = XCAR (val);
ret = Ffuncall (nargs, args); ret = Ffuncall (nargs, args);
} }
} }
@ -2169,18 +2169,18 @@ run_hook_list_with_args (funlist, nargs, args)
globals = Qnil; globals = Qnil;
GCPRO3 (sym, val, globals); GCPRO3 (sym, val, globals);
for (val = funlist; CONSP (val); val = XCONS (val)->cdr) for (val = funlist; CONSP (val); val = XCDR (val))
{ {
if (EQ (XCONS (val)->car, Qt)) if (EQ (XCAR (val), Qt))
{ {
/* t indicates this hook has a local binding; /* t indicates this hook has a local binding;
it means to run the global binding too. */ it means to run the global binding too. */
for (globals = Fdefault_value (sym); for (globals = Fdefault_value (sym);
CONSP (globals); CONSP (globals);
globals = XCONS (globals)->cdr) globals = XCDR (globals))
{ {
args[0] = XCONS (globals)->car; args[0] = XCAR (globals);
/* In a global value, t should not occur. If it does, we /* In a global value, t should not occur. If it does, we
must ignore it to avoid an endless loop. */ must ignore it to avoid an endless loop. */
if (!EQ (args[0], Qt)) if (!EQ (args[0], Qt))
@ -2189,7 +2189,7 @@ run_hook_list_with_args (funlist, nargs, args)
} }
else else
{ {
args[0] = XCONS (val)->car; args[0] = XCAR (val);
Ffuncall (nargs, args); Ffuncall (nargs, args);
} }
} }
@ -2675,8 +2675,8 @@ DEFUN ("fetch-bytecode", Ffetch_bytecode, Sfetch_bytecode,
tem = read_doc_string (XVECTOR (object)->contents[COMPILED_BYTECODE]); tem = read_doc_string (XVECTOR (object)->contents[COMPILED_BYTECODE]);
if (!CONSP (tem)) if (!CONSP (tem))
error ("invalid byte code"); error ("invalid byte code");
XVECTOR (object)->contents[COMPILED_BYTECODE] = XCONS (tem)->car; XVECTOR (object)->contents[COMPILED_BYTECODE] = XCAR (tem);
XVECTOR (object)->contents[COMPILED_CONSTANTS] = XCONS (tem)->cdr; XVECTOR (object)->contents[COMPILED_CONSTANTS] = XCDR (tem);
} }
return object; return object;
} }

View file

@ -344,19 +344,19 @@ use the standard functions without calling themselves recursively.")
inhibited_handlers = Qnil; inhibited_handlers = Qnil;
for (chain = Vfile_name_handler_alist; CONSP (chain); for (chain = Vfile_name_handler_alist; CONSP (chain);
chain = XCONS (chain)->cdr) chain = XCDR (chain))
{ {
Lisp_Object elt; Lisp_Object elt;
elt = XCONS (chain)->car; elt = XCAR (chain);
if (CONSP (elt)) if (CONSP (elt))
{ {
Lisp_Object string; Lisp_Object string;
string = XCONS (elt)->car; string = XCAR (elt);
if (STRINGP (string) && fast_string_match (string, filename) >= 0) if (STRINGP (string) && fast_string_match (string, filename) >= 0)
{ {
Lisp_Object handler, tem; Lisp_Object handler, tem;
handler = XCONS (elt)->cdr; handler = XCDR (elt);
tem = Fmemq (handler, inhibited_handlers); tem = Fmemq (handler, inhibited_handlers);
if (NILP (tem)) if (NILP (tem))
return handler; return handler;
@ -3375,8 +3375,8 @@ actually used.")
{ {
val = call6 (handler, Qinsert_file_contents, filename, val = call6 (handler, Qinsert_file_contents, filename,
visit, beg, end, replace); visit, beg, end, replace);
if (CONSP (val) && CONSP (XCONS (val)->cdr)) if (CONSP (val) && CONSP (XCDR (val)))
inserted = XINT (XCONS (XCONS (val)->cdr)->car); inserted = XINT (XCAR (XCDR (val)));
goto handled; goto handled;
} }
@ -3550,7 +3550,7 @@ actually used.")
args[2] = visit, args[3] = beg, args[4] = end, args[5] = replace; args[2] = visit, args[3] = beg, args[4] = end, args[5] = replace;
coding_systems = Ffind_operation_coding_system (6, args); coding_systems = Ffind_operation_coding_system (6, args);
if (CONSP (coding_systems)) if (CONSP (coding_systems))
val = XCONS (coding_systems)->car; val = XCAR (coding_systems);
} }
} }
@ -4083,7 +4083,7 @@ actually used.")
args[2] = visit, args[3] = beg, args[4] = end, args[5] = Qnil; args[2] = visit, args[3] = beg, args[4] = end, args[5] = Qnil;
coding_systems = Ffind_operation_coding_system (6, args); coding_systems = Ffind_operation_coding_system (6, args);
if (CONSP (coding_systems)) if (CONSP (coding_systems))
val = XCONS (coding_systems)->car; val = XCAR (coding_systems);
} }
} }
@ -4357,8 +4357,8 @@ This does code conversion according to the value of\n\
args[3] = filename; args[4] = append; args[5] = visit; args[3] = filename; args[4] = append; args[5] = visit;
args[6] = lockname; args[6] = lockname;
coding_systems = Ffind_operation_coding_system (7, args); coding_systems = Ffind_operation_coding_system (7, args);
if (CONSP (coding_systems) && !NILP (XCONS (coding_systems)->cdr)) if (CONSP (coding_systems) && !NILP (XCDR (coding_systems)))
val = XCONS (coding_systems)->cdr; val = XCDR (coding_systems);
} }
if (NILP (val) if (NILP (val)
@ -5079,8 +5079,8 @@ do_auto_save_unwind (stream) /* used as unwind-protect function */
{ {
auto_saving = 0; auto_saving = 0;
if (!NILP (stream)) if (!NILP (stream))
fclose ((FILE *) (XFASTINT (XCONS (stream)->car) << 16 fclose ((FILE *) (XFASTINT (XCAR (stream)) << 16
| XFASTINT (XCONS (stream)->cdr))); | XFASTINT (XCDR (stream))));
return Qnil; return Qnil;
} }
@ -5141,8 +5141,8 @@ A non-nil CURRENT-ONLY argument means save only current buffer.")
/* Arrange to close that file whether or not we get an error. /* Arrange to close that file whether or not we get an error.
Also reset auto_saving to 0. */ Also reset auto_saving to 0. */
lispstream = Fcons (Qnil, Qnil); lispstream = Fcons (Qnil, Qnil);
XSETFASTINT (XCONS (lispstream)->car, (EMACS_UINT)stream >> 16); XSETFASTINT (XCAR (lispstream), (EMACS_UINT)stream >> 16);
XSETFASTINT (XCONS (lispstream)->cdr, (EMACS_UINT)stream & 0xffff); XSETFASTINT (XCDR (lispstream), (EMACS_UINT)stream & 0xffff);
} }
else else
lispstream = Qnil; lispstream = Qnil;
@ -5165,9 +5165,9 @@ A non-nil CURRENT-ONLY argument means save only current buffer.")
autosave perfectly ordinary files because it couldn't handle some autosave perfectly ordinary files because it couldn't handle some
ange-ftp'd file. */ ange-ftp'd file. */
for (do_handled_files = 0; do_handled_files < 2; do_handled_files++) for (do_handled_files = 0; do_handled_files < 2; do_handled_files++)
for (tail = Vbuffer_alist; GC_CONSP (tail); tail = XCONS (tail)->cdr) for (tail = Vbuffer_alist; GC_CONSP (tail); tail = XCDR (tail))
{ {
buf = XCONS (XCONS (tail)->car)->cdr; buf = XCDR (XCAR (tail));
b = XBUFFER (buf); b = XBUFFER (buf);
/* Record all the buffers that have auto save mode /* Record all the buffers that have auto save mode
@ -5524,7 +5524,7 @@ DIR defaults to current buffer's directory default.")
Qfile_name_history, default_filename, Qnil); Qfile_name_history, default_filename, Qnil);
tem = Fsymbol_value (Qfile_name_history); tem = Fsymbol_value (Qfile_name_history);
if (CONSP (tem) && EQ (XCONS (tem)->car, val)) if (CONSP (tem) && EQ (XCAR (tem), val))
replace_in_history = 1; replace_in_history = 1;
/* If Fcompleting_read returned the inserted default string itself /* If Fcompleting_read returned the inserted default string itself
@ -5563,14 +5563,14 @@ DIR defaults to current buffer's directory default.")
if (replace_in_history) if (replace_in_history)
/* Replace what Fcompleting_read added to the history /* Replace what Fcompleting_read added to the history
with what we will actually return. */ with what we will actually return. */
XCONS (Fsymbol_value (Qfile_name_history))->car = double_dollars (val); XCAR (Fsymbol_value (Qfile_name_history)) = double_dollars (val);
else if (add_to_history) else if (add_to_history)
{ {
/* Add the value to the history--but not if it matches /* Add the value to the history--but not if it matches
the last value already there. */ the last value already there. */
Lisp_Object val1 = double_dollars (val); Lisp_Object val1 = double_dollars (val);
tem = Fsymbol_value (Qfile_name_history); tem = Fsymbol_value (Qfile_name_history);
if (! CONSP (tem) || NILP (Fequal (XCONS (tem)->car, val1))) if (! CONSP (tem) || NILP (Fequal (XCAR (tem), val1)))
Fset (Qfile_name_history, Fset (Qfile_name_history,
Fcons (val1, tem)); Fcons (val1, tem));
} }

View file

@ -623,9 +623,9 @@ unlock_all_files ()
register Lisp_Object tail; register Lisp_Object tail;
register struct buffer *b; register struct buffer *b;
for (tail = Vbuffer_alist; GC_CONSP (tail); tail = XCONS (tail)->cdr) for (tail = Vbuffer_alist; GC_CONSP (tail); tail = XCDR (tail))
{ {
b = XBUFFER (XCONS (XCONS (tail)->car)->cdr); b = XBUFFER (XCDR (XCAR (tail)));
if (STRINGP (b->file_truename) && BUF_SAVE_MODIFF (b) < BUF_MODIFF (b)) if (STRINGP (b->file_truename) && BUF_SAVE_MODIFF (b) < BUF_MODIFF (b))
{ {
register char *lfname; register char *lfname;

View file

@ -2660,26 +2660,26 @@ DEFUN ("combine-after-change-execute", Fcombine_after_change_execute,
/* Scan the various individual changes, /* Scan the various individual changes,
accumulating the range info in BEG, END and CHANGE. */ accumulating the range info in BEG, END and CHANGE. */
for (tail = combine_after_change_list; CONSP (tail); for (tail = combine_after_change_list; CONSP (tail);
tail = XCONS (tail)->cdr) tail = XCDR (tail))
{ {
Lisp_Object elt; Lisp_Object elt;
int thisbeg, thisend, thischange; int thisbeg, thisend, thischange;
/* Extract the info from the next element. */ /* Extract the info from the next element. */
elt = XCONS (tail)->car; elt = XCAR (tail);
if (! CONSP (elt)) if (! CONSP (elt))
continue; continue;
thisbeg = XINT (XCONS (elt)->car); thisbeg = XINT (XCAR (elt));
elt = XCONS (elt)->cdr; elt = XCDR (elt);
if (! CONSP (elt)) if (! CONSP (elt))
continue; continue;
thisend = XINT (XCONS (elt)->car); thisend = XINT (XCAR (elt));
elt = XCONS (elt)->cdr; elt = XCDR (elt);
if (! CONSP (elt)) if (! CONSP (elt))
continue; continue;
thischange = XINT (XCONS (elt)->car); thischange = XINT (XCAR (elt));
/* Merge this range into the accumulated range. */ /* Merge this range into the accumulated range. */
change += thischange; change += thischange;

View file

@ -867,7 +867,7 @@ adjust_intervals_for_insertion (tree, position, length)
for (tail = i->plist; ! NILP (tail); tail = Fcdr (Fcdr (tail))) for (tail = i->plist; ! NILP (tail); tail = Fcdr (Fcdr (tail)))
{ {
Lisp_Object prop; Lisp_Object prop;
prop = XCONS (tail)->car; prop = XCAR (tail);
/* Is this particular property rear-sticky? /* Is this particular property rear-sticky?
Note, if REAR isn't a cons, it must be non-nil, Note, if REAR isn't a cons, it must be non-nil,

View file

@ -231,7 +231,7 @@ get_keymap_1 (object, error, autoload)
else else
{ {
tem = indirect_function (object); tem = indirect_function (object);
if (CONSP (tem) && EQ (XCONS (tem)->car, Qkeymap)) if (CONSP (tem) && EQ (XCAR (tem), Qkeymap))
return tem; return tem;
} }
@ -240,7 +240,7 @@ get_keymap_1 (object, error, autoload)
if (autoload if (autoload
&& SYMBOLP (object) && SYMBOLP (object)
&& CONSP (tem) && CONSP (tem)
&& EQ (XCONS (tem)->car, Qautoload)) && EQ (XCAR (tem), Qautoload))
{ {
Lisp_Object tail; Lisp_Object tail;
@ -287,11 +287,11 @@ DEFUN ("keymap-parent", Fkeymap_parent, Skeymap_parent, 1, 1, 0,
keymap = get_keymap_1 (keymap, 1, 1); keymap = get_keymap_1 (keymap, 1, 1);
/* Skip past the initial element `keymap'. */ /* Skip past the initial element `keymap'. */
list = XCONS (keymap)->cdr; list = XCDR (keymap);
for (; CONSP (list); list = XCONS (list)->cdr) for (; CONSP (list); list = XCDR (list))
{ {
/* See if there is another `keymap'. */ /* See if there is another `keymap'. */
if (EQ (Qkeymap, XCONS (list)->car)) if (EQ (Qkeymap, XCAR (list)))
return list; return list;
} }
@ -317,17 +317,17 @@ PARENT should be nil or another keymap.")
prev = keymap; prev = keymap;
while (1) while (1)
{ {
list = XCONS (prev)->cdr; list = XCDR (prev);
/* If there is a parent keymap here, replace it. /* If there is a parent keymap here, replace it.
If we came to the end, add the parent in PREV. */ If we came to the end, add the parent in PREV. */
if (! CONSP (list) || EQ (Qkeymap, XCONS (list)->car)) if (! CONSP (list) || EQ (Qkeymap, XCAR (list)))
{ {
/* If we already have the right parent, return now /* If we already have the right parent, return now
so that we avoid the loops below. */ so that we avoid the loops below. */
if (EQ (XCONS (prev)->cdr, parent)) if (EQ (XCDR (prev), parent))
return parent; return parent;
XCONS (prev)->cdr = parent; XCDR (prev) = parent;
break; break;
} }
prev = list; prev = list;
@ -335,29 +335,29 @@ PARENT should be nil or another keymap.")
/* Scan through for submaps, and set their parents too. */ /* Scan through for submaps, and set their parents too. */
for (list = XCONS (keymap)->cdr; CONSP (list); list = XCONS (list)->cdr) for (list = XCDR (keymap); CONSP (list); list = XCDR (list))
{ {
/* Stop the scan when we come to the parent. */ /* Stop the scan when we come to the parent. */
if (EQ (XCONS (list)->car, Qkeymap)) if (EQ (XCAR (list), Qkeymap))
break; break;
/* If this element holds a prefix map, deal with it. */ /* If this element holds a prefix map, deal with it. */
if (CONSP (XCONS (list)->car) if (CONSP (XCAR (list))
&& CONSP (XCONS (XCONS (list)->car)->cdr)) && CONSP (XCDR (XCAR (list))))
fix_submap_inheritance (keymap, XCONS (XCONS (list)->car)->car, fix_submap_inheritance (keymap, XCAR (XCAR (list)),
XCONS (XCONS (list)->car)->cdr); XCDR (XCAR (list)));
if (VECTORP (XCONS (list)->car)) if (VECTORP (XCAR (list)))
for (i = 0; i < XVECTOR (XCONS (list)->car)->size; i++) for (i = 0; i < XVECTOR (XCAR (list))->size; i++)
if (CONSP (XVECTOR (XCONS (list)->car)->contents[i])) if (CONSP (XVECTOR (XCAR (list))->contents[i]))
fix_submap_inheritance (keymap, make_number (i), fix_submap_inheritance (keymap, make_number (i),
XVECTOR (XCONS (list)->car)->contents[i]); XVECTOR (XCAR (list))->contents[i]);
if (CHAR_TABLE_P (XCONS (list)->car)) if (CHAR_TABLE_P (XCAR (list)))
{ {
Lisp_Object indices[3]; Lisp_Object indices[3];
map_char_table (fix_submap_inheritance, Qnil, XCONS (list)->car, map_char_table (fix_submap_inheritance, Qnil, XCAR (list),
keymap, 0, indices); keymap, 0, indices);
} }
} }
@ -381,37 +381,37 @@ fix_submap_inheritance (map, event, submap)
if (CONSP (submap)) if (CONSP (submap))
{ {
/* May be an old format menu item */ /* May be an old format menu item */
if (STRINGP (XCONS (submap)->car)) if (STRINGP (XCAR (submap)))
{ {
submap = XCONS (submap)->cdr; submap = XCDR (submap);
/* Also remove a menu help string, if any, /* Also remove a menu help string, if any,
following the menu item name. */ following the menu item name. */
if (CONSP (submap) && STRINGP (XCONS (submap)->car)) if (CONSP (submap) && STRINGP (XCAR (submap)))
submap = XCONS (submap)->cdr; submap = XCDR (submap);
/* Also remove the sublist that caches key equivalences, if any. */ /* Also remove the sublist that caches key equivalences, if any. */
if (CONSP (submap) if (CONSP (submap)
&& CONSP (XCONS (submap)->car)) && CONSP (XCAR (submap)))
{ {
Lisp_Object carcar; Lisp_Object carcar;
carcar = XCONS (XCONS (submap)->car)->car; carcar = XCAR (XCAR (submap));
if (NILP (carcar) || VECTORP (carcar)) if (NILP (carcar) || VECTORP (carcar))
submap = XCONS (submap)->cdr; submap = XCDR (submap);
} }
} }
/* Or a new format menu item */ /* Or a new format menu item */
else if (EQ (XCONS (submap)->car, Qmenu_item) else if (EQ (XCAR (submap), Qmenu_item)
&& CONSP (XCONS (submap)->cdr)) && CONSP (XCDR (submap)))
{ {
submap = XCONS (XCONS (submap)->cdr)->cdr; submap = XCDR (XCDR (submap));
if (CONSP (submap)) if (CONSP (submap))
submap = XCONS (submap)->car; submap = XCAR (submap);
} }
} }
/* If it isn't a keymap now, there's no work to do. */ /* If it isn't a keymap now, there's no work to do. */
if (! CONSP (submap) if (! CONSP (submap)
|| ! EQ (XCONS (submap)->car, Qkeymap)) || ! EQ (XCAR (submap), Qkeymap))
return; return;
map_parent = Fkeymap_parent (map); map_parent = Fkeymap_parent (map);
@ -422,7 +422,7 @@ fix_submap_inheritance (map, event, submap)
/* If MAP's parent has something other than a keymap, /* If MAP's parent has something other than a keymap,
our own submap shadows it completely, so use nil as SUBMAP's parent. */ our own submap shadows it completely, so use nil as SUBMAP's parent. */
if (! (CONSP (parent_entry) && EQ (XCONS (parent_entry)->car, Qkeymap))) if (! (CONSP (parent_entry) && EQ (XCAR (parent_entry), Qkeymap)))
parent_entry = Qnil; parent_entry = Qnil;
if (! EQ (parent_entry, submap)) if (! EQ (parent_entry, submap))
@ -436,7 +436,7 @@ fix_submap_inheritance (map, event, submap)
if (EQ (tem, parent_entry)) if (EQ (tem, parent_entry))
return; return;
if (CONSP (tem) if (CONSP (tem)
&& EQ (XCONS (tem)->car, Qkeymap)) && EQ (XCAR (tem), Qkeymap))
submap_parent = tem; submap_parent = tem;
else else
break; break;
@ -486,11 +486,11 @@ access_keymap (map, idx, t_ok, noinherit)
Lisp_Object t_binding; Lisp_Object t_binding;
t_binding = Qnil; t_binding = Qnil;
for (tail = map; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = map; CONSP (tail); tail = XCDR (tail))
{ {
Lisp_Object binding; Lisp_Object binding;
binding = XCONS (tail)->car; binding = XCAR (tail);
if (SYMBOLP (binding)) if (SYMBOLP (binding))
{ {
/* If NOINHERIT, stop finding prefix definitions /* If NOINHERIT, stop finding prefix definitions
@ -500,24 +500,24 @@ access_keymap (map, idx, t_ok, noinherit)
} }
else if (CONSP (binding)) else if (CONSP (binding))
{ {
if (EQ (XCONS (binding)->car, idx)) if (EQ (XCAR (binding), idx))
{ {
val = XCONS (binding)->cdr; val = XCDR (binding);
if (noprefix && CONSP (val) && EQ (XCONS (val)->car, Qkeymap)) if (noprefix && CONSP (val) && EQ (XCAR (val), Qkeymap))
return Qnil; return Qnil;
if (CONSP (val)) if (CONSP (val))
fix_submap_inheritance (map, idx, val); fix_submap_inheritance (map, idx, val);
return val; return val;
} }
if (t_ok && EQ (XCONS (binding)->car, Qt)) if (t_ok && EQ (XCAR (binding), Qt))
t_binding = XCONS (binding)->cdr; t_binding = XCDR (binding);
} }
else if (VECTORP (binding)) else if (VECTORP (binding))
{ {
if (NATNUMP (idx) && XFASTINT (idx) < XVECTOR (binding)->size) if (NATNUMP (idx) && XFASTINT (idx) < XVECTOR (binding)->size)
{ {
val = XVECTOR (binding)->contents[XFASTINT (idx)]; val = XVECTOR (binding)->contents[XFASTINT (idx)];
if (noprefix && CONSP (val) && EQ (XCONS (val)->car, Qkeymap)) if (noprefix && CONSP (val) && EQ (XCAR (val), Qkeymap))
return Qnil; return Qnil;
if (CONSP (val)) if (CONSP (val))
fix_submap_inheritance (map, idx, val); fix_submap_inheritance (map, idx, val);
@ -535,7 +535,7 @@ access_keymap (map, idx, t_ok, noinherit)
| CHAR_SHIFT | CHAR_CTL | CHAR_META))) | CHAR_SHIFT | CHAR_CTL | CHAR_META)))
{ {
val = Faref (binding, idx); val = Faref (binding, idx);
if (noprefix && CONSP (val) && EQ (XCONS (val)->car, Qkeymap)) if (noprefix && CONSP (val) && EQ (XCAR (val), Qkeymap))
return Qnil; return Qnil;
if (CONSP (val)) if (CONSP (val))
fix_submap_inheritance (map, idx, val); fix_submap_inheritance (map, idx, val);
@ -651,10 +651,10 @@ store_in_keymap (keymap, idx, def)
/* If we are preparing to dump, and DEF is a menu element /* If we are preparing to dump, and DEF is a menu element
with a menu item indicator, copy it to ensure it is not pure. */ with a menu item indicator, copy it to ensure it is not pure. */
if (CONSP (def) && PURE_P (def) if (CONSP (def) && PURE_P (def)
&& (EQ (XCONS (def)->car, Qmenu_item) || STRINGP (XCONS (def)->car))) && (EQ (XCAR (def), Qmenu_item) || STRINGP (XCAR (def))))
def = Fcons (XCONS (def)->car, XCONS (def)->cdr); def = Fcons (XCAR (def), XCDR (def));
if (!CONSP (keymap) || ! EQ (XCONS (keymap)->car, Qkeymap)) if (!CONSP (keymap) || ! EQ (XCAR (keymap), Qkeymap))
error ("attempt to define a key in a non-keymap"); error ("attempt to define a key in a non-keymap");
/* If idx is a list (some sort of mouse click, perhaps?), /* If idx is a list (some sort of mouse click, perhaps?),
@ -684,11 +684,11 @@ store_in_keymap (keymap, idx, def)
Lisp_Object insertion_point; Lisp_Object insertion_point;
insertion_point = keymap; insertion_point = keymap;
for (tail = XCONS (keymap)->cdr; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = XCDR (keymap); CONSP (tail); tail = XCDR (tail))
{ {
Lisp_Object elt; Lisp_Object elt;
elt = XCONS (tail)->car; elt = XCAR (tail);
if (VECTORP (elt)) if (VECTORP (elt))
{ {
if (NATNUMP (idx) && XFASTINT (idx) < XVECTOR (elt)->size) if (NATNUMP (idx) && XFASTINT (idx) < XVECTOR (elt)->size)
@ -715,9 +715,9 @@ store_in_keymap (keymap, idx, def)
} }
else if (CONSP (elt)) else if (CONSP (elt))
{ {
if (EQ (idx, XCONS (elt)->car)) if (EQ (idx, XCAR (elt)))
{ {
XCONS (elt)->cdr = def; XCDR (elt) = def;
return def; return def;
} }
} }
@ -737,8 +737,8 @@ store_in_keymap (keymap, idx, def)
keymap_end: keymap_end:
/* We have scanned the entire keymap, and not found a binding for /* We have scanned the entire keymap, and not found a binding for
IDX. Let's add one. */ IDX. Let's add one. */
XCONS (insertion_point)->cdr XCDR (insertion_point)
= Fcons (Fcons (idx, def), XCONS (insertion_point)->cdr); = Fcons (Fcons (idx, def), XCDR (insertion_point));
} }
return def; return def;
@ -766,17 +766,17 @@ is not copied.")
copy = Fcopy_alist (get_keymap (keymap)); copy = Fcopy_alist (get_keymap (keymap));
for (tail = copy; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = copy; CONSP (tail); tail = XCDR (tail))
{ {
Lisp_Object elt; Lisp_Object elt;
elt = XCONS (tail)->car; elt = XCAR (tail);
if (CHAR_TABLE_P (elt)) if (CHAR_TABLE_P (elt))
{ {
Lisp_Object indices[3]; Lisp_Object indices[3];
elt = Fcopy_sequence (elt); elt = Fcopy_sequence (elt);
XCONS (tail)->car = elt; XCAR (tail) = elt;
map_char_table (copy_keymap_1, Qnil, elt, elt, 0, indices); map_char_table (copy_keymap_1, Qnil, elt, elt, 0, indices);
} }
@ -785,7 +785,7 @@ is not copied.")
int i; int i;
elt = Fcopy_sequence (elt); elt = Fcopy_sequence (elt);
XCONS (tail)->car = elt; XCAR (tail) = elt;
for (i = 0; i < XVECTOR (elt)->size; i++) for (i = 0; i < XVECTOR (elt)->size; i++)
if (!SYMBOLP (XVECTOR (elt)->contents[i]) if (!SYMBOLP (XVECTOR (elt)->contents[i])
@ -793,41 +793,41 @@ is not copied.")
XVECTOR (elt)->contents[i] XVECTOR (elt)->contents[i]
= Fcopy_keymap (XVECTOR (elt)->contents[i]); = Fcopy_keymap (XVECTOR (elt)->contents[i]);
} }
else if (CONSP (elt) && CONSP (XCONS (elt)->cdr)) else if (CONSP (elt) && CONSP (XCDR (elt)))
{ {
Lisp_Object tem; Lisp_Object tem;
tem = XCONS (elt)->cdr; tem = XCDR (elt);
/* Is this a new format menu item. */ /* Is this a new format menu item. */
if (EQ (XCONS (tem)->car,Qmenu_item)) if (EQ (XCAR (tem),Qmenu_item))
{ {
/* Copy cell with menu-item marker. */ /* Copy cell with menu-item marker. */
XCONS (elt)->cdr XCDR (elt)
= Fcons (XCONS (tem)->car, XCONS (tem)->cdr); = Fcons (XCAR (tem), XCDR (tem));
elt = XCONS (elt)->cdr; elt = XCDR (elt);
tem = XCONS (elt)->cdr; tem = XCDR (elt);
if (CONSP (tem)) if (CONSP (tem))
{ {
/* Copy cell with menu-item name. */ /* Copy cell with menu-item name. */
XCONS (elt)->cdr XCDR (elt)
= Fcons (XCONS (tem)->car, XCONS (tem)->cdr); = Fcons (XCAR (tem), XCDR (tem));
elt = XCONS (elt)->cdr; elt = XCDR (elt);
tem = XCONS (elt)->cdr; tem = XCDR (elt);
}; };
if (CONSP (tem)) if (CONSP (tem))
{ {
/* Copy cell with binding and if the binding is a keymap, /* Copy cell with binding and if the binding is a keymap,
copy that. */ copy that. */
XCONS (elt)->cdr XCDR (elt)
= Fcons (XCONS (tem)->car, XCONS (tem)->cdr); = Fcons (XCAR (tem), XCDR (tem));
elt = XCONS (elt)->cdr; elt = XCDR (elt);
tem = XCONS (elt)->car; tem = XCAR (elt);
if (!(SYMBOLP (tem) || NILP (Fkeymapp (tem)))) if (!(SYMBOLP (tem) || NILP (Fkeymapp (tem))))
XCONS (elt)->car = Fcopy_keymap (tem); XCAR (elt) = Fcopy_keymap (tem);
tem = XCONS (elt)->cdr; tem = XCDR (elt);
if (CONSP (tem) && CONSP (XCONS (tem)->car)) if (CONSP (tem) && CONSP (XCAR (tem)))
/* Delete cache for key equivalences. */ /* Delete cache for key equivalences. */
XCONS (elt)->cdr = XCONS (tem)->cdr; XCDR (elt) = XCDR (tem);
} }
} }
else else
@ -835,33 +835,33 @@ is not copied.")
/* It may be an old fomat menu item. /* It may be an old fomat menu item.
Skip the optional menu string. Skip the optional menu string.
*/ */
if (STRINGP (XCONS (tem)->car)) if (STRINGP (XCAR (tem)))
{ {
/* Copy the cell, since copy-alist didn't go this deep. */ /* Copy the cell, since copy-alist didn't go this deep. */
XCONS (elt)->cdr XCDR (elt)
= Fcons (XCONS (tem)->car, XCONS (tem)->cdr); = Fcons (XCAR (tem), XCDR (tem));
elt = XCONS (elt)->cdr; elt = XCDR (elt);
tem = XCONS (elt)->cdr; tem = XCDR (elt);
/* Also skip the optional menu help string. */ /* Also skip the optional menu help string. */
if (CONSP (tem) && STRINGP (XCONS (tem)->car)) if (CONSP (tem) && STRINGP (XCAR (tem)))
{ {
XCONS (elt)->cdr XCDR (elt)
= Fcons (XCONS (tem)->car, XCONS (tem)->cdr); = Fcons (XCAR (tem), XCDR (tem));
elt = XCONS (elt)->cdr; elt = XCDR (elt);
tem = XCONS (elt)->cdr; tem = XCDR (elt);
} }
/* There may also be a list that caches key equivalences. /* There may also be a list that caches key equivalences.
Just delete it for the new keymap. */ Just delete it for the new keymap. */
if (CONSP (tem) if (CONSP (tem)
&& CONSP (XCONS (tem)->car) && CONSP (XCAR (tem))
&& (NILP (XCONS (XCONS (tem)->car)->car) && (NILP (XCAR (XCAR (tem)))
|| VECTORP (XCONS (XCONS (tem)->car)->car))) || VECTORP (XCAR (XCAR (tem)))))
XCONS (elt)->cdr = XCONS (tem)->cdr; XCDR (elt) = XCDR (tem);
} }
if (CONSP (elt) if (CONSP (elt)
&& ! SYMBOLP (XCONS (elt)->cdr) && ! SYMBOLP (XCDR (elt))
&& ! NILP (Fkeymapp (XCONS (elt)->cdr))) && ! NILP (Fkeymapp (XCDR (elt))))
XCONS (elt)->cdr = Fcopy_keymap (XCONS (elt)->cdr); XCDR (elt) = Fcopy_keymap (XCDR (elt));
} }
} }
@ -1093,8 +1093,8 @@ define_as_prefix (keymap, c)
make it define this key. */ make it define this key. */
Lisp_Object tail; Lisp_Object tail;
for (tail = Fcdr (keymap); CONSP (tail); tail = XCONS (tail)->cdr) for (tail = Fcdr (keymap); CONSP (tail); tail = XCDR (tail))
if (EQ (XCONS (tail)->car, Qkeymap)) if (EQ (XCAR (tail), Qkeymap))
break; break;
if (!NILP (tail)) if (!NILP (tail))
@ -1169,9 +1169,9 @@ current_minor_maps (modeptr, mapptr)
for (list_number = 0; list_number < 2; list_number++) for (list_number = 0; list_number < 2; list_number++)
for (alist = lists[list_number]; for (alist = lists[list_number];
CONSP (alist); CONSP (alist);
alist = XCONS (alist)->cdr) alist = XCDR (alist))
if ((assoc = XCONS (alist)->car, CONSP (assoc)) if ((assoc = XCAR (alist), CONSP (assoc))
&& (var = XCONS (assoc)->car, SYMBOLP (var)) && (var = XCAR (assoc), SYMBOLP (var))
&& (val = find_symbol_value (var), ! EQ (val, Qunbound)) && (val = find_symbol_value (var), ! EQ (val, Qunbound))
&& ! NILP (val)) && ! NILP (val))
{ {
@ -1225,7 +1225,7 @@ current_minor_maps (modeptr, mapptr)
/* Get the keymap definition--or nil if it is not defined. */ /* Get the keymap definition--or nil if it is not defined. */
temp = internal_condition_case_1 (Findirect_function, temp = internal_condition_case_1 (Findirect_function,
XCONS (assoc)->cdr, XCDR (assoc),
Qerror, current_minor_maps_error); Qerror, current_minor_maps_error);
if (!NILP (temp)) if (!NILP (temp))
{ {
@ -1536,7 +1536,7 @@ then the value includes only maps for prefixes that start with PREFIX.")
This is a breadth-first traversal, where tail is the queue of This is a breadth-first traversal, where tail is the queue of
nodes, and maps accumulates a list of all nodes visited. */ nodes, and maps accumulates a list of all nodes visited. */
for (tail = maps; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = maps; CONSP (tail); tail = XCDR (tail))
{ {
register Lisp_Object thisseq, thismap; register Lisp_Object thisseq, thismap;
Lisp_Object last; Lisp_Object last;
@ -1551,11 +1551,11 @@ then the value includes only maps for prefixes that start with PREFIX.")
&& XINT (last) >= prefixlen && XINT (last) >= prefixlen
&& EQ (Faref (thisseq, last), meta_prefix_char)); && EQ (Faref (thisseq, last), meta_prefix_char));
for (; CONSP (thismap); thismap = XCONS (thismap)->cdr) for (; CONSP (thismap); thismap = XCDR (thismap))
{ {
Lisp_Object elt; Lisp_Object elt;
elt = XCONS (thismap)->car; elt = XCAR (thismap);
QUIT; QUIT;
@ -1602,8 +1602,8 @@ then the value includes only maps for prefixes that start with PREFIX.")
/* This new sequence is the same length as /* This new sequence is the same length as
thisseq, so stick it in the list right thisseq, so stick it in the list right
after this one. */ after this one. */
XCONS (tail)->cdr XCDR (tail)
= Fcons (Fcons (tem, cmd), XCONS (tail)->cdr); = Fcons (Fcons (tem, cmd), XCDR (tail));
} }
else else
{ {
@ -1618,7 +1618,7 @@ then the value includes only maps for prefixes that start with PREFIX.")
{ {
register Lisp_Object cmd, tem, filter; register Lisp_Object cmd, tem, filter;
cmd = get_keyelt (XCONS (elt)->cdr, 0); cmd = get_keyelt (XCDR (elt), 0);
/* Ignore definitions that aren't keymaps themselves. */ /* Ignore definitions that aren't keymaps themselves. */
tem = Fkeymapp (cmd); tem = Fkeymapp (cmd);
if (!NILP (tem)) if (!NILP (tem))
@ -1629,7 +1629,7 @@ then the value includes only maps for prefixes that start with PREFIX.")
if (NILP (tem)) if (NILP (tem))
{ {
/* Let elt be the event defined by this map entry. */ /* Let elt be the event defined by this map entry. */
elt = XCONS (elt)->car; elt = XCAR (elt);
/* If the last key in thisseq is meta-prefix-char, and /* If the last key in thisseq is meta-prefix-char, and
this entry is a binding for an ascii keystroke, this entry is a binding for an ascii keystroke,
@ -1646,8 +1646,8 @@ then the value includes only maps for prefixes that start with PREFIX.")
/* This new sequence is the same length as /* This new sequence is the same length as
thisseq, so stick it in the list right thisseq, so stick it in the list right
after this one. */ after this one. */
XCONS (tail)->cdr XCDR (tail)
= Fcons (Fcons (tem, cmd), XCONS (tail)->cdr); = Fcons (Fcons (tem, cmd), XCDR (tail));
} }
else else
nconc2 (tail, nconc2 (tail,
@ -1665,11 +1665,11 @@ then the value includes only maps for prefixes that start with PREFIX.")
/* Now find just the maps whose access prefixes start with PREFIX. */ /* Now find just the maps whose access prefixes start with PREFIX. */
good_maps = Qnil; good_maps = Qnil;
for (; CONSP (maps); maps = XCONS (maps)->cdr) for (; CONSP (maps); maps = XCDR (maps))
{ {
Lisp_Object elt, thisseq; Lisp_Object elt, thisseq;
elt = XCONS (maps)->car; elt = XCAR (maps);
thisseq = XCONS (elt)->car; thisseq = XCAR (elt);
/* The access prefix must be at least as long as PREFIX, /* The access prefix must be at least as long as PREFIX,
and the first elements must match those of PREFIX. */ and the first elements must match those of PREFIX. */
if (XINT (Flength (thisseq)) >= prefixlen) if (XINT (Flength (thisseq)) >= prefixlen)
@ -1700,9 +1700,9 @@ accessible_keymaps_char_table (args, index, cmd)
if (NILP (cmd)) if (NILP (cmd))
return; return;
maps = XCONS (args)->car; maps = XCAR (args);
tail = XCONS (XCONS (args)->cdr)->car; tail = XCAR (XCDR (args));
thisseq = XCONS (XCONS (args)->cdr)->cdr; thisseq = XCDR (XCDR (args));
tem = Fkeymapp (cmd); tem = Fkeymapp (cmd);
if (!NILP (tem)) if (!NILP (tem))
@ -1787,9 +1787,9 @@ spaces are put between sequence elements, etc.")
for (i = 0; i < len; i++) for (i = 0; i < len; i++)
{ {
args[i * 2] = Fsingle_key_description (XCONS (keys)->car); args[i * 2] = Fsingle_key_description (XCAR (keys));
args[i * 2 + 1] = sep; args[i * 2 + 1] = sep;
keys = XCONS (keys)->cdr; keys = XCDR (keys);
} }
} }
else else
@ -2106,10 +2106,10 @@ indirect definition itself.")
minors = Fnreverse (Fcurrent_minor_mode_maps ()); minors = Fnreverse (Fcurrent_minor_mode_maps ());
while (!NILP (minors)) while (!NILP (minors))
{ {
maps = nconc2 (Faccessible_keymaps (get_keymap (XCONS (minors)->car), maps = nconc2 (Faccessible_keymaps (get_keymap (XCAR (minors)),
Qnil), Qnil),
maps); maps);
minors = XCONS (minors)->cdr; minors = XCDR (minors);
} }
} }
@ -2147,8 +2147,8 @@ indirect definition itself.")
advance map to the next element until i indicates that we advance map to the next element until i indicates that we
have finished off the vector. */ have finished off the vector. */
Lisp_Object elt, key, binding; Lisp_Object elt, key, binding;
elt = XCONS (map)->car; elt = XCAR (map);
map = XCONS (map)->cdr; map = XCDR (map);
sequences = Qnil; sequences = Qnil;
@ -2185,14 +2185,14 @@ indirect definition itself.")
map_char_table (where_is_internal_2, Qnil, elt, args, map_char_table (where_is_internal_2, Qnil, elt, args,
0, indices); 0, indices);
sequences = XCONS (XCONS (XCONS (args)->car)->cdr)->cdr; sequences = XCDR (XCDR (XCAR (args)));
} }
else if (CONSP (elt)) else if (CONSP (elt))
{ {
Lisp_Object sequence; Lisp_Object sequence;
key = XCONS (elt)->car; key = XCAR (elt);
binding = XCONS (elt)->cdr; binding = XCDR (elt);
sequence = where_is_internal_1 (binding, key, definition, sequence = where_is_internal_1 (binding, key, definition,
noindirect, keymap, this, noindirect, keymap, this,
@ -2202,11 +2202,11 @@ indirect definition itself.")
} }
for (; ! NILP (sequences); sequences = XCONS (sequences)->cdr) for (; ! NILP (sequences); sequences = XCDR (sequences))
{ {
Lisp_Object sequence; Lisp_Object sequence;
sequence = XCONS (sequences)->car; sequence = XCAR (sequences);
/* It is a true unshadowed match. Record it, unless it's already /* It is a true unshadowed match. Record it, unless it's already
been seen (as could happen when inheriting keymaps). */ been seen (as could happen when inheriting keymaps). */
@ -2254,20 +2254,20 @@ where_is_internal_2 (args, key, binding)
Lisp_Object result, sequence; Lisp_Object result, sequence;
int nomenus, last_is_meta; int nomenus, last_is_meta;
result = XCONS (XCONS (XCONS (args)->car)->cdr)->cdr; result = XCDR (XCDR (XCAR (args)));
definition = XCONS (XCONS (XCONS (args)->car)->car)->car; definition = XCAR (XCAR (XCAR (args)));
noindirect = XCONS (XCONS (XCONS (args)->car)->car)->cdr; noindirect = XCDR (XCAR (XCAR (args)));
keymap = XCONS (XCONS (XCONS (args)->car)->cdr)->car; keymap = XCAR (XCDR (XCAR (args)));
this = XCONS (XCONS (XCONS (args)->cdr)->car)->car; this = XCAR (XCAR (XCDR (args)));
last = XCONS (XCONS (XCONS (args)->cdr)->car)->cdr; last = XCDR (XCAR (XCDR (args)));
nomenus = XFASTINT (XCONS (XCONS (XCONS (args)->cdr)->cdr)->car); nomenus = XFASTINT (XCAR (XCDR (XCDR (args))));
last_is_meta = XFASTINT (XCONS (XCONS (XCONS (args)->cdr)->cdr)->cdr); last_is_meta = XFASTINT (XCDR (XCDR (XCDR (args))));
sequence = where_is_internal_1 (binding, key, definition, noindirect, keymap, sequence = where_is_internal_1 (binding, key, definition, noindirect, keymap,
this, last, nomenus, last_is_meta); this, last, nomenus, last_is_meta);
if (!NILP (sequence)) if (!NILP (sequence))
XCONS (XCONS (XCONS (args)->car)->cdr)->cdr XCDR (XCDR (XCAR (args)))
= Fcons (sequence, result); = Fcons (sequence, result);
} }
@ -2298,8 +2298,8 @@ where_is_internal_1 (binding, key, definition, noindirect, keymap, this, last,
} }
/* If the contents are (menu-item ...) or (STRING ...), reject. */ /* If the contents are (menu-item ...) or (STRING ...), reject. */
if (CONSP (definition) if (CONSP (definition)
&& (EQ (XCONS (definition)->car,Qmenu_item) && (EQ (XCAR (definition),Qmenu_item)
|| STRINGP (XCONS (definition)->car))) || STRINGP (XCAR (definition))))
return Qnil; return Qnil;
} }
else else
@ -2404,11 +2404,11 @@ Keyboard translations:\n\n\
You type Translation\n\ You type Translation\n\
-------- -----------\n"; -------- -----------\n";
descbuf = XCONS (arg)->car; descbuf = XCAR (arg);
arg = XCONS (arg)->cdr; arg = XCDR (arg);
prefix = XCONS (arg)->car; prefix = XCAR (arg);
arg = XCONS (arg)->cdr; arg = XCDR (arg);
nomenu = NILP (XCONS (arg)->car); nomenu = NILP (XCAR (arg));
shadow = Qnil; shadow = Qnil;
GCPRO1 (shadow); GCPRO1 (shadow);
@ -2566,7 +2566,7 @@ key binding\n\
Lisp_Object list; Lisp_Object list;
/* Delete from MAPS each element that is for the menu bar. */ /* Delete from MAPS each element that is for the menu bar. */
for (list = maps; !NILP (list); list = XCONS (list)->cdr) for (list = maps; !NILP (list); list = XCDR (list))
{ {
Lisp_Object elt, prefix, tem; Lisp_Object elt, prefix, tem;
@ -2606,11 +2606,11 @@ key binding\n\
sub_shadows = Qnil; sub_shadows = Qnil;
for (tail = shadow; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = shadow; CONSP (tail); tail = XCDR (tail))
{ {
Lisp_Object shmap; Lisp_Object shmap;
shmap = XCONS (tail)->car; shmap = XCAR (tail);
/* If the sequence by which we reach this keymap is zero-length, /* If the sequence by which we reach this keymap is zero-length,
then the shadow map for this keymap is just SHADOW. */ then the shadow map for this keymap is just SHADOW. */
@ -2740,9 +2740,9 @@ shadow_lookup (shadow, key, flag)
{ {
Lisp_Object tail, value; Lisp_Object tail, value;
for (tail = shadow; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = shadow; CONSP (tail); tail = XCDR (tail))
{ {
value = Flookup_key (XCONS (tail)->car, key, flag); value = Flookup_key (XCAR (tail), key, flag);
if (!NILP (value)) if (!NILP (value))
return value; return value;
} }
@ -2791,18 +2791,18 @@ describe_map (map, keys, elt_describer, partial, shadow, seen, nomenu)
GCPRO3 (elt_prefix, definition, kludge); GCPRO3 (elt_prefix, definition, kludge);
for (tail = map; CONSP (tail); tail = XCONS (tail)->cdr) for (tail = map; CONSP (tail); tail = XCDR (tail))
{ {
QUIT; QUIT;
if (VECTORP (XCONS (tail)->car) if (VECTORP (XCAR (tail))
|| CHAR_TABLE_P (XCONS (tail)->car)) || CHAR_TABLE_P (XCAR (tail)))
describe_vector (XCONS (tail)->car, describe_vector (XCAR (tail),
elt_prefix, elt_describer, partial, shadow, map, elt_prefix, elt_describer, partial, shadow, map,
(int *)0, 0); (int *)0, 0);
else if (CONSP (XCONS (tail)->car)) else if (CONSP (XCAR (tail)))
{ {
event = XCONS (XCONS (tail)->car)->car; event = XCAR (XCAR (tail));
/* Ignore bindings whose "keys" are not really valid events. /* Ignore bindings whose "keys" are not really valid events.
(We get these in the frames and buffers menu.) */ (We get these in the frames and buffers menu.) */
@ -2812,7 +2812,7 @@ describe_map (map, keys, elt_describer, partial, shadow, seen, nomenu)
if (nomenu && EQ (event, Qmenu_bar)) if (nomenu && EQ (event, Qmenu_bar))
continue; continue;
definition = get_keyelt (XCONS (XCONS (tail)->car)->cdr, 0); definition = get_keyelt (XCDR (XCAR (tail)), 0);
/* Don't show undefined commands or suppressed commands. */ /* Don't show undefined commands or suppressed commands. */
if (NILP (definition)) continue; if (NILP (definition)) continue;
@ -2854,13 +2854,13 @@ describe_map (map, keys, elt_describer, partial, shadow, seen, nomenu)
for alignment purposes. */ for alignment purposes. */
(*elt_describer) (definition); (*elt_describer) (definition);
} }
else if (EQ (XCONS (tail)->car, Qkeymap)) else if (EQ (XCAR (tail), Qkeymap))
{ {
/* The same keymap might be in the structure twice, if we're /* The same keymap might be in the structure twice, if we're
using an inherited keymap. So skip anything we've already using an inherited keymap. So skip anything we've already
encountered. */ encountered. */
tem = Fassq (tail, *seen); tem = Fassq (tail, *seen);
if (CONSP (tem) && !NILP (Fequal (XCONS (tem)->car, keys))) if (CONSP (tem) && !NILP (Fequal (XCAR (tem), keys)))
break; break;
*seen = Fcons (Fcons (tail, keys), *seen); *seen = Fcons (Fcons (tail, keys), *seen);
} }