aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKen Raeburn1999-09-12 07:05:34 +0000
committerKen Raeburn1999-09-12 07:05:34 +0000
commit8e713be64cb396e4fa30d8a393987b77d6cd99f6 (patch)
tree8ca8beed123bcd05a9849f9a575fbc73ca17edad
parent70949dac51f3e975477e6b1a38cc78625efc4a40 (diff)
downloademacs-8e713be64cb396e4fa30d8a393987b77d6cd99f6.tar.gz
emacs-8e713be64cb396e4fa30d8a393987b77d6cd99f6.zip
Use XCAR and XCDR instead of explicit member references.
-rw-r--r--src/w32faces.c24
-rw-r--r--src/w32fns.c192
-rw-r--r--src/w32menu.c20
-rw-r--r--src/w32proc.c8
-rw-r--r--src/w32term.c20
-rw-r--r--src/xfns.c110
-rw-r--r--src/xmenu.c20
-rw-r--r--src/xselect.c134
-rw-r--r--src/xterm.c90
9 files changed, 309 insertions, 309 deletions
diff --git a/src/w32faces.c b/src/w32faces.c
index 6b9356a95b0..61aeee17794 100644
--- a/src/w32faces.c
+++ b/src/w32faces.c
@@ -302,16 +302,16 @@ DEFUN ("pixmap-spec-p", Fpixmap_spec_p, Spixmap_spec_p, 1, 1, 0,
302 302
303 return ((STRINGP (object) 303 return ((STRINGP (object)
304 || (CONSP (object) 304 || (CONSP (object)
305 && CONSP (XCONS (object)->cdr) 305 && CONSP (XCDR (object))
306 && CONSP (XCONS (XCONS (object)->cdr)->cdr) 306 && CONSP (XCDR (XCDR (object)))
307 && NILP (XCONS (XCONS (XCONS (object)->cdr)->cdr)->cdr) 307 && NILP (XCDR (XCDR (XCDR (object))))
308 && (width = XCONS (object)->car, INTEGERP (width)) 308 && (width = XCAR (object), INTEGERP (width))
309 && (height = XCONS (XCONS (object)->cdr)->car, INTEGERP (height)) 309 && (height = XCAR (XCDR (object)), INTEGERP (height))
310 && STRINGP (XCONS (XCONS (XCONS (object)->cdr)->cdr)->car) 310 && STRINGP (XCAR (XCDR (XCDR (object))))
311 && XINT (width) > 0 311 && XINT (width) > 0
312 && XINT (height) > 0 312 && XINT (height) > 0
313 /* The string must have enough bits for width * height. */ 313 /* The string must have enough bits for width * height. */
314 && ((XSTRING (XCONS (XCONS (XCONS (object)->cdr)->cdr)->car)->size 314 && ((XSTRING (XCAR (XCDR (XCDR (object))))->size
315 * (BITS_PER_INT / sizeof (int))) 315 * (BITS_PER_INT / sizeof (int)))
316 >= XFASTINT (width) * XFASTINT (height)))) 316 >= XFASTINT (width) * XFASTINT (height))))
317 ? Qt : Qnil); 317 ? Qt : Qnil);
@@ -828,7 +828,7 @@ merge_face_list (f, face, prop)
828 int j; 828 int j;
829 829
830 if (CONSP (prop) 830 if (CONSP (prop)
831 && ! STRINGP (XCONS (prop)->cdr)) 831 && ! STRINGP (XCDR (prop)))
832 { 832 {
833 /* We have a list of faces, merge them in reverse order. */ 833 /* We have a list of faces, merge them in reverse order. */
834 834
@@ -855,10 +855,10 @@ merge_face_list (f, face, prop)
855 { 855 {
856 if (CONSP (faces[j])) 856 if (CONSP (faces[j]))
857 { 857 {
858 if (EQ (XCONS (faces[j])->car, Qbackground_color)) 858 if (EQ (XCAR (faces[j]), Qbackground_color))
859 face->background = load_color (f, XCONS (faces[j])->cdr); 859 face->background = load_color (f, XCDR (faces[j]));
860 if (EQ (XCONS (faces[j])->car, Qforeground_color)) 860 if (EQ (XCAR (faces[j]), Qforeground_color))
861 face->foreground = load_color (f, XCONS (faces[j])->cdr); 861 face->foreground = load_color (f, XCDR (faces[j]));
862 } 862 }
863 else 863 else
864 { 864 {
diff --git a/src/w32fns.c b/src/w32fns.c
index 79574f5b82a..a3f3e2a0d87 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -341,9 +341,9 @@ x_window_to_frame (dpyinfo, wdesc)
341 Lisp_Object tail, frame; 341 Lisp_Object tail, frame;
342 struct frame *f; 342 struct frame *f;
343 343
344 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 344 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
345 { 345 {
346 frame = XCONS (tail)->car; 346 frame = XCAR (tail);
347 if (!GC_FRAMEP (frame)) 347 if (!GC_FRAMEP (frame))
348 continue; 348 continue;
349 f = XFRAME (frame); 349 f = XFRAME (frame);
@@ -867,18 +867,18 @@ x_set_frame_parameters (f, alist)
867 if (leftpos < 0) 867 if (leftpos < 0)
868 f->output_data.w32->size_hint_flags |= XNegative; 868 f->output_data.w32->size_hint_flags |= XNegative;
869 } 869 }
870 else if (CONSP (left) && EQ (XCONS (left)->car, Qminus) 870 else if (CONSP (left) && EQ (XCAR (left), Qminus)
871 && CONSP (XCONS (left)->cdr) 871 && CONSP (XCDR (left))
872 && INTEGERP (XCONS (XCONS (left)->cdr)->car)) 872 && INTEGERP (XCAR (XCDR (left))))
873 { 873 {
874 leftpos = - XINT (XCONS (XCONS (left)->cdr)->car); 874 leftpos = - XINT (XCAR (XCDR (left)));
875 f->output_data.w32->size_hint_flags |= XNegative; 875 f->output_data.w32->size_hint_flags |= XNegative;
876 } 876 }
877 else if (CONSP (left) && EQ (XCONS (left)->car, Qplus) 877 else if (CONSP (left) && EQ (XCAR (left), Qplus)
878 && CONSP (XCONS (left)->cdr) 878 && CONSP (XCDR (left))
879 && INTEGERP (XCONS (XCONS (left)->cdr)->car)) 879 && INTEGERP (XCAR (XCDR (left))))
880 { 880 {
881 leftpos = XINT (XCONS (XCONS (left)->cdr)->car); 881 leftpos = XINT (XCAR (XCDR (left)));
882 } 882 }
883 883
884 if (EQ (top, Qminus)) 884 if (EQ (top, Qminus))
@@ -889,18 +889,18 @@ x_set_frame_parameters (f, alist)
889 if (toppos < 0) 889 if (toppos < 0)
890 f->output_data.w32->size_hint_flags |= YNegative; 890 f->output_data.w32->size_hint_flags |= YNegative;
891 } 891 }
892 else if (CONSP (top) && EQ (XCONS (top)->car, Qminus) 892 else if (CONSP (top) && EQ (XCAR (top), Qminus)
893 && CONSP (XCONS (top)->cdr) 893 && CONSP (XCDR (top))
894 && INTEGERP (XCONS (XCONS (top)->cdr)->car)) 894 && INTEGERP (XCAR (XCDR (top))))
895 { 895 {
896 toppos = - XINT (XCONS (XCONS (top)->cdr)->car); 896 toppos = - XINT (XCAR (XCDR (top)));
897 f->output_data.w32->size_hint_flags |= YNegative; 897 f->output_data.w32->size_hint_flags |= YNegative;
898 } 898 }
899 else if (CONSP (top) && EQ (XCONS (top)->car, Qplus) 899 else if (CONSP (top) && EQ (XCAR (top), Qplus)
900 && CONSP (XCONS (top)->cdr) 900 && CONSP (XCDR (top))
901 && INTEGERP (XCONS (XCONS (top)->cdr)->car)) 901 && INTEGERP (XCAR (XCDR (top))))
902 { 902 {
903 toppos = XINT (XCONS (XCONS (top)->cdr)->car); 903 toppos = XINT (XCAR (XCDR (top)));
904 } 904 }
905 905
906 906
@@ -989,7 +989,7 @@ x_report_frame_params (f, alistptr)
989 (FRAME_VISIBLE_P (f) ? Qt 989 (FRAME_VISIBLE_P (f) ? Qt
990 : FRAME_ICONIFIED_P (f) ? Qicon : Qnil)); 990 : FRAME_ICONIFIED_P (f) ? Qicon : Qnil));
991 store_in_alist (alistptr, Qdisplay, 991 store_in_alist (alistptr, Qdisplay,
992 XCONS (FRAME_W32_DISPLAY_INFO (f)->name_list_element)->car); 992 XCAR (FRAME_W32_DISPLAY_INFO (f)->name_list_element));
993} 993}
994 994
995 995
@@ -2049,11 +2049,11 @@ x_set_cursor_type (f, arg, oldval)
2049 FRAME_DESIRED_CURSOR (f) = bar_cursor; 2049 FRAME_DESIRED_CURSOR (f) = bar_cursor;
2050 f->output_data.w32->cursor_width = 2; 2050 f->output_data.w32->cursor_width = 2;
2051 } 2051 }
2052 else if (CONSP (arg) && EQ (XCONS (arg)->car, Qbar) 2052 else if (CONSP (arg) && EQ (XCAR (arg), Qbar)
2053 && INTEGERP (XCONS (arg)->cdr)) 2053 && INTEGERP (XCDR (arg)))
2054 { 2054 {
2055 FRAME_DESIRED_CURSOR (f) = bar_cursor; 2055 FRAME_DESIRED_CURSOR (f) = bar_cursor;
2056 f->output_data.w32->cursor_width = XINT (XCONS (arg)->cdr); 2056 f->output_data.w32->cursor_width = XINT (XCDR (arg));
2057 } 2057 }
2058 else 2058 else
2059 /* Treat anything unknown as "box cursor". 2059 /* Treat anything unknown as "box cursor".
@@ -2105,7 +2105,7 @@ x_icon_type (f)
2105 2105
2106 tem = assq_no_quit (Qicon_type, f->param_alist); 2106 tem = assq_no_quit (Qicon_type, f->param_alist);
2107 if (CONSP (tem)) 2107 if (CONSP (tem))
2108 return XCONS (tem)->cdr; 2108 return XCDR (tem);
2109 else 2109 else
2110 return Qnil; 2110 return Qnil;
2111} 2111}
@@ -2885,18 +2885,18 @@ x_figure_window_size (f, parms)
2885 f->output_data.w32->top_pos = 0; 2885 f->output_data.w32->top_pos = 0;
2886 window_prompting |= YNegative; 2886 window_prompting |= YNegative;
2887 } 2887 }
2888 else if (CONSP (tem0) && EQ (XCONS (tem0)->car, Qminus) 2888 else if (CONSP (tem0) && EQ (XCAR (tem0), Qminus)
2889 && CONSP (XCONS (tem0)->cdr) 2889 && CONSP (XCDR (tem0))
2890 && INTEGERP (XCONS (XCONS (tem0)->cdr)->car)) 2890 && INTEGERP (XCAR (XCDR (tem0))))
2891 { 2891 {
2892 f->output_data.w32->top_pos = - XINT (XCONS (XCONS (tem0)->cdr)->car); 2892 f->output_data.w32->top_pos = - XINT (XCAR (XCDR (tem0)));
2893 window_prompting |= YNegative; 2893 window_prompting |= YNegative;
2894 } 2894 }
2895 else if (CONSP (tem0) && EQ (XCONS (tem0)->car, Qplus) 2895 else if (CONSP (tem0) && EQ (XCAR (tem0), Qplus)
2896 && CONSP (XCONS (tem0)->cdr) 2896 && CONSP (XCDR (tem0))
2897 && INTEGERP (XCONS (XCONS (tem0)->cdr)->car)) 2897 && INTEGERP (XCAR (XCDR (tem0))))
2898 { 2898 {
2899 f->output_data.w32->top_pos = XINT (XCONS (XCONS (tem0)->cdr)->car); 2899 f->output_data.w32->top_pos = XINT (XCAR (XCDR (tem0)));
2900 } 2900 }
2901 else if (EQ (tem0, Qunbound)) 2901 else if (EQ (tem0, Qunbound))
2902 f->output_data.w32->top_pos = 0; 2902 f->output_data.w32->top_pos = 0;
@@ -2913,18 +2913,18 @@ x_figure_window_size (f, parms)
2913 f->output_data.w32->left_pos = 0; 2913 f->output_data.w32->left_pos = 0;
2914 window_prompting |= XNegative; 2914 window_prompting |= XNegative;
2915 } 2915 }
2916 else if (CONSP (tem1) && EQ (XCONS (tem1)->car, Qminus) 2916 else if (CONSP (tem1) && EQ (XCAR (tem1), Qminus)
2917 && CONSP (XCONS (tem1)->cdr) 2917 && CONSP (XCDR (tem1))
2918 && INTEGERP (XCONS (XCONS (tem1)->cdr)->car)) 2918 && INTEGERP (XCAR (XCDR (tem1))))
2919 { 2919 {
2920 f->output_data.w32->left_pos = - XINT (XCONS (XCONS (tem1)->cdr)->car); 2920 f->output_data.w32->left_pos = - XINT (XCAR (XCDR (tem1)));
2921 window_prompting |= XNegative; 2921 window_prompting |= XNegative;
2922 } 2922 }
2923 else if (CONSP (tem1) && EQ (XCONS (tem1)->car, Qplus) 2923 else if (CONSP (tem1) && EQ (XCAR (tem1), Qplus)
2924 && CONSP (XCONS (tem1)->cdr) 2924 && CONSP (XCDR (tem1))
2925 && INTEGERP (XCONS (XCONS (tem1)->cdr)->car)) 2925 && INTEGERP (XCAR (XCDR (tem1))))
2926 { 2926 {
2927 f->output_data.w32->left_pos = XINT (XCONS (XCONS (tem1)->cdr)->car); 2927 f->output_data.w32->left_pos = XINT (XCAR (XCDR (tem1)));
2928 } 2928 }
2929 else if (EQ (tem1, Qunbound)) 2929 else if (EQ (tem1, Qunbound))
2930 f->output_data.w32->left_pos = 0; 2930 f->output_data.w32->left_pos = 0;
@@ -4833,8 +4833,8 @@ This function is an internal primitive--use `make-frame' instead.")
4833 } 4833 }
4834 4834
4835 /* Create fontsets from `global_fontset_alist' before handling fonts. */ 4835 /* Create fontsets from `global_fontset_alist' before handling fonts. */
4836 for (tem = Vglobal_fontset_alist; CONSP (tem); tem = XCONS (tem)->cdr) 4836 for (tem = Vglobal_fontset_alist; CONSP (tem); tem = XCDR (tem))
4837 fs_register_fontset (f, XCONS (tem)->car); 4837 fs_register_fontset (f, XCAR (tem));
4838 4838
4839 /* Extract the window parameters from the supplied values 4839 /* Extract the window parameters from the supplied values
4840 that are needed to determine window geometry. */ 4840 that are needed to determine window geometry. */
@@ -5052,14 +5052,14 @@ w32_load_system_font (f,fontname,size)
5052 /* First check if any are already loaded, as that is cheaper 5052 /* First check if any are already loaded, as that is cheaper
5053 than loading another one. */ 5053 than loading another one. */
5054 for (i = 0; i < dpyinfo->n_fonts; i++) 5054 for (i = 0; i < dpyinfo->n_fonts; i++)
5055 for (tail = font_names; CONSP (tail); tail = XCONS (tail)->cdr) 5055 for (tail = font_names; CONSP (tail); tail = XCDR (tail))
5056 if (!strcmp (dpyinfo->font_table[i].name, 5056 if (!strcmp (dpyinfo->font_table[i].name,
5057 XSTRING (XCONS (tail)->car)->data) 5057 XSTRING (XCAR (tail))->data)
5058 || !strcmp (dpyinfo->font_table[i].full_name, 5058 || !strcmp (dpyinfo->font_table[i].full_name,
5059 XSTRING (XCONS (tail)->car)->data)) 5059 XSTRING (XCAR (tail))->data))
5060 return (dpyinfo->font_table + i); 5060 return (dpyinfo->font_table + i);
5061#endif 5061#endif
5062 fontname = (char *) XSTRING (XCONS (font_names)->car)->data; 5062 fontname = (char *) XSTRING (XCAR (font_names))->data;
5063 } 5063 }
5064 else if (w32_strict_fontnames) 5064 else if (w32_strict_fontnames)
5065 { 5065 {
@@ -5234,13 +5234,13 @@ int size;
5234 char *bdf_name, *bdf_file; 5234 char *bdf_name, *bdf_file;
5235 Lisp_Object bdf_pair; 5235 Lisp_Object bdf_pair;
5236 5236
5237 bdf_name = XSTRING (XCONS (bdf_fonts)->car)->data; 5237 bdf_name = XSTRING (XCAR (bdf_fonts))->data;
5238 bdf_pair = Fassoc (XCONS (bdf_fonts)->car, Vw32_bdf_filename_alist); 5238 bdf_pair = Fassoc (XCAR (bdf_fonts), Vw32_bdf_filename_alist);
5239 bdf_file = XSTRING (XCONS (bdf_pair)->cdr)->data; 5239 bdf_file = XSTRING (XCDR (bdf_pair))->data;
5240 5240
5241 retval = w32_load_bdf_font (f, bdf_name, size, bdf_file); 5241 retval = w32_load_bdf_font (f, bdf_name, size, bdf_file);
5242 5242
5243 bdf_fonts = XCONS (bdf_fonts)->cdr; 5243 bdf_fonts = XCDR (bdf_fonts);
5244 } 5244 }
5245 5245
5246 if (retval) 5246 if (retval)
@@ -5831,7 +5831,7 @@ enum_font_cb2 (lplf, lptm, FontType, lpef)
5831 || w32_font_match (buf, XSTRING (*(lpef->pattern))->data)) 5831 || w32_font_match (buf, XSTRING (*(lpef->pattern))->data))
5832 { 5832 {
5833 *lpef->tail = Fcons (Fcons (build_string (buf), width), Qnil); 5833 *lpef->tail = Fcons (Fcons (build_string (buf), width), Qnil);
5834 lpef->tail = &(XCONS (*lpef->tail)->cdr); 5834 lpef->tail = &(XCDR (*lpef->tail));
5835 lpef->numFonts++; 5835 lpef->numFonts++;
5836 } 5836 }
5837 } 5837 }
@@ -5899,11 +5899,11 @@ Lisp_Object w32_list_bdf_fonts (Lisp_Object pattern, int max_names)
5899 list = Vw32_bdf_filename_alist; 5899 list = Vw32_bdf_filename_alist;
5900 ptnstr = XSTRING (pattern)->data; 5900 ptnstr = XSTRING (pattern)->data;
5901 5901
5902 for ( ; CONSP (list); list = XCONS (list)->cdr) 5902 for ( ; CONSP (list); list = XCDR (list))
5903 { 5903 {
5904 tem = XCONS (list)->car; 5904 tem = XCAR (list);
5905 if (CONSP (tem)) 5905 if (CONSP (tem))
5906 fontname = XSTRING (XCONS (tem)->car)->data; 5906 fontname = XSTRING (XCAR (tem))->data;
5907 else if (STRINGP (tem)) 5907 else if (STRINGP (tem))
5908 fontname = XSTRING (tem)->data; 5908 fontname = XSTRING (tem)->data;
5909 else 5909 else
@@ -5911,7 +5911,7 @@ Lisp_Object w32_list_bdf_fonts (Lisp_Object pattern, int max_names)
5911 5911
5912 if (w32_font_match (fontname, ptnstr)) 5912 if (w32_font_match (fontname, ptnstr))
5913 { 5913 {
5914 newlist = Fcons (XCONS (tem)->car, newlist); 5914 newlist = Fcons (XCAR (tem), newlist);
5915 n_fonts++; 5915 n_fonts++;
5916 if (n_fonts >= max_names) 5916 if (n_fonts >= max_names)
5917 break; 5917 break;
@@ -5943,17 +5943,17 @@ w32_list_fonts (FRAME_PTR f, Lisp_Object pattern, int size, int maxnames )
5943 if (NILP (patterns)) 5943 if (NILP (patterns))
5944 patterns = Fcons (pattern, Qnil); 5944 patterns = Fcons (pattern, Qnil);
5945 5945
5946 for (; CONSP (patterns); patterns = XCONS (patterns)->cdr) 5946 for (; CONSP (patterns); patterns = XCDR (patterns))
5947 { 5947 {
5948 enumfont_t ef; 5948 enumfont_t ef;
5949 5949
5950 tpat = XCONS (patterns)->car; 5950 tpat = XCAR (patterns);
5951 5951
5952 /* See if we cached the result for this particular query. 5952 /* See if we cached the result for this particular query.
5953 The cache is an alist of the form: 5953 The cache is an alist of the form:
5954 ((PATTERN (FONTNAME . WIDTH) ...) ...) 5954 ((PATTERN (FONTNAME . WIDTH) ...) ...)
5955 */ 5955 */
5956 if (tem = XCONS (dpyinfo->name_list_element)->cdr, 5956 if (tem = XCDR (dpyinfo->name_list_element),
5957 !NILP (list = Fassoc (tpat, tem))) 5957 !NILP (list = Fassoc (tpat, tem)))
5958 { 5958 {
5959 list = Fcdr_safe (list); 5959 list = Fcdr_safe (list);
@@ -6004,9 +6004,9 @@ w32_list_fonts (FRAME_PTR f, Lisp_Object pattern, int size, int maxnames )
6004 6004
6005 /* Make a list of the fonts we got back. 6005 /* Make a list of the fonts we got back.
6006 Store that in the font cache for the display. */ 6006 Store that in the font cache for the display. */
6007 XCONS (dpyinfo->name_list_element)->cdr 6007 XCDR (dpyinfo->name_list_element)
6008 = Fcons (Fcons (tpat, list), 6008 = Fcons (Fcons (tpat, list),
6009 XCONS (dpyinfo->name_list_element)->cdr); 6009 XCDR (dpyinfo->name_list_element));
6010 6010
6011 label_cached: 6011 label_cached:
6012 if (NILP (list)) continue; /* Try the remaining alternatives. */ 6012 if (NILP (list)) continue; /* Try the remaining alternatives. */
@@ -6014,25 +6014,25 @@ w32_list_fonts (FRAME_PTR f, Lisp_Object pattern, int size, int maxnames )
6014 newlist = second_best = Qnil; 6014 newlist = second_best = Qnil;
6015 6015
6016 /* Make a list of the fonts that have the right width. */ 6016 /* Make a list of the fonts that have the right width. */
6017 for (; CONSP (list); list = XCONS (list)->cdr) 6017 for (; CONSP (list); list = XCDR (list))
6018 { 6018 {
6019 int found_size; 6019 int found_size;
6020 tem = XCONS (list)->car; 6020 tem = XCAR (list);
6021 6021
6022 if (!CONSP (tem)) 6022 if (!CONSP (tem))
6023 continue; 6023 continue;
6024 if (NILP (XCONS (tem)->car)) 6024 if (NILP (XCAR (tem)))
6025 continue; 6025 continue;
6026 if (!size) 6026 if (!size)
6027 { 6027 {
6028 newlist = Fcons (XCONS (tem)->car, newlist); 6028 newlist = Fcons (XCAR (tem), newlist);
6029 n_fonts++; 6029 n_fonts++;
6030 if (n_fonts >= maxnames) 6030 if (n_fonts >= maxnames)
6031 break; 6031 break;
6032 else 6032 else
6033 continue; 6033 continue;
6034 } 6034 }
6035 if (!INTEGERP (XCONS (tem)->cdr)) 6035 if (!INTEGERP (XCDR (tem)))
6036 { 6036 {
6037 /* Since we don't yet know the size of the font, we must 6037 /* Since we don't yet know the size of the font, we must
6038 load it and try GetTextMetrics. */ 6038 load it and try GetTextMetrics. */
@@ -6041,7 +6041,7 @@ w32_list_fonts (FRAME_PTR f, Lisp_Object pattern, int size, int maxnames )
6041 HDC hdc; 6041 HDC hdc;
6042 HANDLE oldobj; 6042 HANDLE oldobj;
6043 6043
6044 if (!x_to_w32_font (XSTRING (XCONS (tem)->car)->data, &lf)) 6044 if (!x_to_w32_font (XSTRING (XCAR (tem))->data, &lf))
6045 continue; 6045 continue;
6046 6046
6047 BLOCK_INPUT; 6047 BLOCK_INPUT;
@@ -6053,18 +6053,18 @@ w32_list_fonts (FRAME_PTR f, Lisp_Object pattern, int size, int maxnames )
6053 hdc = GetDC (dpyinfo->root_window); 6053 hdc = GetDC (dpyinfo->root_window);
6054 oldobj = SelectObject (hdc, thisinfo.hfont); 6054 oldobj = SelectObject (hdc, thisinfo.hfont);
6055 if (GetTextMetrics (hdc, &thisinfo.tm)) 6055 if (GetTextMetrics (hdc, &thisinfo.tm))
6056 XCONS (tem)->cdr = make_number (FONT_WIDTH (&thisinfo)); 6056 XCDR (tem) = make_number (FONT_WIDTH (&thisinfo));
6057 else 6057 else
6058 XCONS (tem)->cdr = make_number (0); 6058 XCDR (tem) = make_number (0);
6059 SelectObject (hdc, oldobj); 6059 SelectObject (hdc, oldobj);
6060 ReleaseDC (dpyinfo->root_window, hdc); 6060 ReleaseDC (dpyinfo->root_window, hdc);
6061 DeleteObject(thisinfo.hfont); 6061 DeleteObject(thisinfo.hfont);
6062 UNBLOCK_INPUT; 6062 UNBLOCK_INPUT;
6063 } 6063 }
6064 found_size = XINT (XCONS (tem)->cdr); 6064 found_size = XINT (XCDR (tem));
6065 if (found_size == size) 6065 if (found_size == size)
6066 { 6066 {
6067 newlist = Fcons (XCONS (tem)->car, newlist); 6067 newlist = Fcons (XCAR (tem), newlist);
6068 n_fonts++; 6068 n_fonts++;
6069 if (n_fonts >= maxnames) 6069 if (n_fonts >= maxnames)
6070 break; 6070 break;
@@ -6078,14 +6078,14 @@ w32_list_fonts (FRAME_PTR f, Lisp_Object pattern, int size, int maxnames )
6078 6078
6079 else if (found_size < size) 6079 else if (found_size < size)
6080 { 6080 {
6081 if (XINT (XCONS (second_best)->cdr) > size 6081 if (XINT (XCDR (second_best)) > size
6082 || XINT (XCONS (second_best)->cdr) < found_size) 6082 || XINT (XCDR (second_best)) < found_size)
6083 second_best = tem; 6083 second_best = tem;
6084 } 6084 }
6085 else 6085 else
6086 { 6086 {
6087 if (XINT (XCONS (second_best)->cdr) > size 6087 if (XINT (XCDR (second_best)) > size
6088 && XINT (XCONS (second_best)->cdr) > 6088 && XINT (XCDR (second_best)) >
6089 found_size) 6089 found_size)
6090 second_best = tem; 6090 second_best = tem;
6091 } 6091 }
@@ -6096,7 +6096,7 @@ w32_list_fonts (FRAME_PTR f, Lisp_Object pattern, int size, int maxnames )
6096 break; 6096 break;
6097 else if (!NILP (second_best)) 6097 else if (!NILP (second_best))
6098 { 6098 {
6099 newlist = Fcons (XCONS (second_best)->car, Qnil); 6099 newlist = Fcons (XCAR (second_best), Qnil);
6100 break; 6100 break;
6101 } 6101 }
6102 } 6102 }
@@ -6150,9 +6150,9 @@ w32_list_synthesized_fonts (f, pattern, size, max_names)
6150 6150
6151 matches = w32_list_fonts (f, build_string (new_pattn), size, max_names); 6151 matches = w32_list_fonts (f, build_string (new_pattn), size, max_names);
6152 6152
6153 for ( ; CONSP (matches); matches = XCONS (matches)->cdr) 6153 for ( ; CONSP (matches); matches = XCDR (matches))
6154 { 6154 {
6155 tem = XCONS (matches)->car; 6155 tem = XCAR (matches);
6156 if (!STRINGP (tem)) 6156 if (!STRINGP (tem))
6157 continue; 6157 continue;
6158 6158
@@ -6208,12 +6208,12 @@ w32_find_ccl_program (fontp)
6208{ 6208{
6209 Lisp_Object list, elt; 6209 Lisp_Object list, elt;
6210 6210
6211 for (list = Vfont_ccl_encoder_alist; CONSP (list); list = XCONS (list)->cdr) 6211 for (list = Vfont_ccl_encoder_alist; CONSP (list); list = XCDR (list))
6212 { 6212 {
6213 elt = XCONS (list)->car; 6213 elt = XCAR (list);
6214 if (CONSP (elt) 6214 if (CONSP (elt)
6215 && STRINGP (XCONS (elt)->car) 6215 && STRINGP (XCAR (elt))
6216 && (fast_c_string_match_ignore_case (XCONS (elt)->car, fontp->name) 6216 && (fast_c_string_match_ignore_case (XCAR (elt), fontp->name)
6217 >= 0)) 6217 >= 0))
6218 break; 6218 break;
6219 } 6219 }
@@ -6222,7 +6222,7 @@ w32_find_ccl_program (fontp)
6222 struct ccl_program *ccl 6222 struct ccl_program *ccl
6223 = (struct ccl_program *) xmalloc (sizeof (struct ccl_program)); 6223 = (struct ccl_program *) xmalloc (sizeof (struct ccl_program));
6224 6224
6225 if (setup_ccl_program (ccl, XCONS (elt)->cdr) < 0) 6225 if (setup_ccl_program (ccl, XCDR (elt)) < 0)
6226 xfree (ccl); 6226 xfree (ccl);
6227 else 6227 else
6228 fontp->font_encoder = ccl; 6228 fontp->font_encoder = ccl;
@@ -6297,7 +6297,7 @@ fonts to match. The first MAXIMUM fonts are reported.")
6297 6297
6298 /* See if we cached the result for this particular query. */ 6298 /* See if we cached the result for this particular query. */
6299 list = Fassoc (pattern, 6299 list = Fassoc (pattern,
6300 XCONS (FRAME_W32_DISPLAY_INFO (f)->name_list_element)->cdr); 6300 XCDR (FRAME_W32_DISPLAY_INFO (f)->name_list_element));
6301 6301
6302 /* We have info in the cache for this PATTERN. */ 6302 /* We have info in the cache for this PATTERN. */
6303 if (!NILP (list)) 6303 if (!NILP (list))
@@ -6305,7 +6305,7 @@ fonts to match. The first MAXIMUM fonts are reported.")
6305 Lisp_Object tem, newlist; 6305 Lisp_Object tem, newlist;
6306 6306
6307 /* We have info about this pattern. */ 6307 /* We have info about this pattern. */
6308 list = XCONS (list)->cdr; 6308 list = XCDR (list);
6309 6309
6310 if (size_ref == 0) 6310 if (size_ref == 0)
6311 return list; 6311 return list;
@@ -6314,16 +6314,16 @@ fonts to match. The first MAXIMUM fonts are reported.")
6314 6314
6315 /* Filter the cached info and return just the fonts that match FACE. */ 6315 /* Filter the cached info and return just the fonts that match FACE. */
6316 newlist = Qnil; 6316 newlist = Qnil;
6317 for (tem = list; CONSP (tem); tem = XCONS (tem)->cdr) 6317 for (tem = list; CONSP (tem); tem = XCDR (tem))
6318 { 6318 {
6319 struct font_info *fontinf; 6319 struct font_info *fontinf;
6320 XFontStruct *thisinfo = NULL; 6320 XFontStruct *thisinfo = NULL;
6321 6321
6322 fontinf = w32_load_font (f, XSTRING (XCONS (tem)->car)->data, 0); 6322 fontinf = w32_load_font (f, XSTRING (XCAR (tem))->data, 0);
6323 if (fontinf) 6323 if (fontinf)
6324 thisinfo = (XFontStruct *)fontinf->font; 6324 thisinfo = (XFontStruct *)fontinf->font;
6325 if (thisinfo && same_size_fonts (thisinfo, size_ref)) 6325 if (thisinfo && same_size_fonts (thisinfo, size_ref))
6326 newlist = Fcons (XCONS (tem)->car, newlist); 6326 newlist = Fcons (XCAR (tem), newlist);
6327 6327
6328 w32_unload_font (FRAME_W32_DISPLAY_INFO (f), thisinfo); 6328 w32_unload_font (FRAME_W32_DISPLAY_INFO (f), thisinfo);
6329 } 6329 }
@@ -6358,9 +6358,9 @@ fonts to match. The first MAXIMUM fonts are reported.")
6358 6358
6359 /* Make a list of all the fonts we got back. 6359 /* Make a list of all the fonts we got back.
6360 Store that in the font cache for the display. */ 6360 Store that in the font cache for the display. */
6361 XCONS (FRAME_W32_DISPLAY_INFO (f)->name_list_element)->cdr 6361 XCDR (FRAME_W32_DISPLAY_INFO (f)->name_list_element)
6362 = Fcons (Fcons (pattern, namelist), 6362 = Fcons (Fcons (pattern, namelist),
6363 XCONS (FRAME_W32_DISPLAY_INFO (f)->name_list_element)->cdr); 6363 XCDR (FRAME_W32_DISPLAY_INFO (f)->name_list_element));
6364 6364
6365 /* Make a list of the fonts that have the right width. */ 6365 /* Make a list of the fonts that have the right width. */
6366 list = Qnil; 6366 list = Qnil;
@@ -6413,13 +6413,13 @@ will not be included in the list. DIR may be a list of directories.")
6413 if (!CONSP (directory)) 6413 if (!CONSP (directory))
6414 return w32_find_bdf_fonts_in_dir (directory); 6414 return w32_find_bdf_fonts_in_dir (directory);
6415 6415
6416 for ( ; CONSP (directory); directory = XCONS (directory)->cdr) 6416 for ( ; CONSP (directory); directory = XCDR (directory))
6417 { 6417 {
6418 Lisp_Object pair[2]; 6418 Lisp_Object pair[2];
6419 pair[0] = list; 6419 pair[0] = list;
6420 pair[1] = Qnil; 6420 pair[1] = Qnil;
6421 GCPRO2 (directory, list); 6421 GCPRO2 (directory, list);
6422 pair[1] = w32_find_bdf_fonts_in_dir( XCONS (directory)->car ); 6422 pair[1] = w32_find_bdf_fonts_in_dir( XCAR (directory) );
6423 list = Fnconc( 2, pair ); 6423 list = Fnconc( 2, pair );
6424 UNGCPRO; 6424 UNGCPRO;
6425 } 6425 }
@@ -6439,9 +6439,9 @@ Lisp_Object w32_find_bdf_fonts_in_dir( Lisp_Object directory )
6439 filelist = Fdirectory_files (directory, Qt, 6439 filelist = Fdirectory_files (directory, Qt,
6440 build_string (".*\\.[bB][dD][fF]"), Qt); 6440 build_string (".*\\.[bB][dD][fF]"), Qt);
6441 6441
6442 for ( ; CONSP(filelist); filelist = XCONS (filelist)->cdr) 6442 for ( ; CONSP(filelist); filelist = XCDR (filelist))
6443 { 6443 {
6444 Lisp_Object filename = XCONS (filelist)->car; 6444 Lisp_Object filename = XCAR (filelist);
6445 if (w32_BDF_to_x_font (XSTRING (filename)->data, fontname, 100)) 6445 if (w32_BDF_to_x_font (XSTRING (filename)->data, fontname, 100))
6446 store_in_alist (&list, build_string (fontname), filename); 6446 store_in_alist (&list, build_string (fontname), filename);
6447 } 6447 }
@@ -6803,10 +6803,10 @@ x_display_info_for_name (name)
6803 6803
6804 for (dpyinfo = &one_w32_display_info, names = w32_display_name_list; 6804 for (dpyinfo = &one_w32_display_info, names = w32_display_name_list;
6805 dpyinfo; 6805 dpyinfo;
6806 dpyinfo = dpyinfo->next, names = XCONS (names)->cdr) 6806 dpyinfo = dpyinfo->next, names = XCDR (names))
6807 { 6807 {
6808 Lisp_Object tem; 6808 Lisp_Object tem;
6809 tem = Fstring_equal (XCONS (XCONS (names)->car)->car, name); 6809 tem = Fstring_equal (XCAR (XCAR (names)), name);
6810 if (!NILP (tem)) 6810 if (!NILP (tem))
6811 return dpyinfo; 6811 return dpyinfo;
6812 } 6812 }
@@ -6949,8 +6949,8 @@ DEFUN ("x-display-list", Fx_display_list, Sx_display_list, 0, 0, 0,
6949 Lisp_Object tail, result; 6949 Lisp_Object tail, result;
6950 6950
6951 result = Qnil; 6951 result = Qnil;
6952 for (tail = w32_display_name_list; ! NILP (tail); tail = XCONS (tail)->cdr) 6952 for (tail = w32_display_name_list; ! NILP (tail); tail = XCDR (tail))
6953 result = Fcons (XCONS (XCONS (tail)->car)->car, result); 6953 result = Fcons (XCAR (XCAR (tail)), result);
6954 6954
6955 return result; 6955 return result;
6956} 6956}
diff --git a/src/w32menu.c b/src/w32menu.c
index 8adaace306a..aa3ef60d12b 100644
--- a/src/w32menu.c
+++ b/src/w32menu.c
@@ -214,9 +214,9 @@ menubar_id_to_frame (HMENU menu)
214 Lisp_Object tail, frame; 214 Lisp_Object tail, frame;
215 FRAME_PTR f; 215 FRAME_PTR f;
216 216
217 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 217 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
218 { 218 {
219 frame = XCONS (tail)->car; 219 frame = XCAR (tail);
220 if (!GC_FRAMEP (frame)) 220 if (!GC_FRAMEP (frame))
221 continue; 221 continue;
222 f = XFRAME (frame); 222 f = XFRAME (frame);
@@ -416,14 +416,14 @@ single_keymap_panes (keymap, pane_name, prefix, notreal, maxdepth)
416 notbuttons = menu_items_used; 416 notbuttons = menu_items_used;
417#endif 417#endif
418 418
419 for (tail = keymap; CONSP (tail); tail = XCONS (tail)->cdr) 419 for (tail = keymap; CONSP (tail); tail = XCDR (tail))
420 { 420 {
421 GCPRO2 (keymap, pending_maps); 421 GCPRO2 (keymap, pending_maps);
422 /* Look at each key binding, and if it is a menu item add it 422 /* Look at each key binding, and if it is a menu item add it
423 to this menu. */ 423 to this menu. */
424 item = XCONS (tail)->car; 424 item = XCAR (tail);
425 if (CONSP (item)) 425 if (CONSP (item))
426 single_menu_item (XCONS (item)->car, XCONS (item)->cdr, 426 single_menu_item (XCAR (item), XCDR (item),
427 &pending_maps, notreal, maxdepth, &notbuttons); 427 &pending_maps, notreal, maxdepth, &notbuttons);
428 else if (VECTORP (item)) 428 else if (VECTORP (item))
429 { 429 {
@@ -446,12 +446,12 @@ single_keymap_panes (keymap, pane_name, prefix, notreal, maxdepth)
446 { 446 {
447 Lisp_Object elt, eltcdr, string; 447 Lisp_Object elt, eltcdr, string;
448 elt = Fcar (pending_maps); 448 elt = Fcar (pending_maps);
449 eltcdr = XCONS (elt)->cdr; 449 eltcdr = XCDR (elt);
450 string = XCONS (eltcdr)->car; 450 string = XCAR (eltcdr);
451 /* We no longer discard the @ from the beginning of the string here. 451 /* We no longer discard the @ from the beginning of the string here.
452 Instead, we do this in w32_menu_show. */ 452 Instead, we do this in w32_menu_show. */
453 single_keymap_panes (Fcar (elt), string, 453 single_keymap_panes (Fcar (elt), string,
454 XCONS (eltcdr)->cdr, notreal, maxdepth - 1); 454 XCDR (eltcdr), notreal, maxdepth - 1);
455 pending_maps = Fcdr (pending_maps); 455 pending_maps = Fcdr (pending_maps);
456 } 456 }
457} 457}
@@ -702,7 +702,7 @@ cached information about equivalent key sequences.")
702 702
703 /* Decode the first argument: find the window and the coordinates. */ 703 /* Decode the first argument: find the window and the coordinates. */
704 if (EQ (position, Qt) 704 if (EQ (position, Qt)
705 || (CONSP (position) && EQ (XCONS (position)->car, Qmenu_bar))) 705 || (CONSP (position) && EQ (XCAR (position), Qmenu_bar)))
706 { 706 {
707 /* Use the mouse's current position. */ 707 /* Use the mouse's current position. */
708 FRAME_PTR new_f = selected_frame; 708 FRAME_PTR new_f = selected_frame;
@@ -900,7 +900,7 @@ on the left of the dialog box and all following items on the right.\n\
900 900
901 /* Decode the first argument: find the window or frame to use. */ 901 /* Decode the first argument: find the window or frame to use. */
902 if (EQ (position, Qt) 902 if (EQ (position, Qt)
903 || (CONSP (position) && EQ (XCONS (position)->car, Qmenu_bar))) 903 || (CONSP (position) && EQ (XCAR (position), Qmenu_bar)))
904 { 904 {
905#if 0 /* Using the frame the mouse is on may not be right. */ 905#if 0 /* Using the frame the mouse is on may not be right. */
906 /* Use the mouse's current position. */ 906 /* Use the mouse's current position. */
diff --git a/src/w32proc.c b/src/w32proc.c
index 97ab6fcc150..c64918c5bd6 100644
--- a/src/w32proc.c
+++ b/src/w32proc.c
@@ -2068,11 +2068,11 @@ If successful, the new layout id is returned, otherwise nil.")
2068 DWORD kl; 2068 DWORD kl;
2069 2069
2070 CHECK_CONS (layout, 0); 2070 CHECK_CONS (layout, 0);
2071 CHECK_NUMBER (XCONS (layout)->car, 0); 2071 CHECK_NUMBER (XCAR (layout), 0);
2072 CHECK_NUMBER (XCONS (layout)->cdr, 0); 2072 CHECK_NUMBER (XCDR (layout), 0);
2073 2073
2074 kl = (XINT (XCONS (layout)->car) & 0xffff) 2074 kl = (XINT (XCAR (layout)) & 0xffff)
2075 | (XINT (XCONS (layout)->cdr) << 16); 2075 | (XINT (XCDR (layout)) << 16);
2076 2076
2077 /* Synchronize layout with input thread. */ 2077 /* Synchronize layout with input thread. */
2078 if (dwWindowsThreadId) 2078 if (dwWindowsThreadId)
diff --git a/src/w32term.c b/src/w32term.c
index 8b426aeb2b6..ac7a173feb1 100644
--- a/src/w32term.c
+++ b/src/w32term.c
@@ -2588,11 +2588,11 @@ x_window_to_scroll_bar (window_id)
2588 2588
2589 for (tail = Vframe_list; 2589 for (tail = Vframe_list;
2590 XGCTYPE (tail) == Lisp_Cons; 2590 XGCTYPE (tail) == Lisp_Cons;
2591 tail = XCONS (tail)->cdr) 2591 tail = XCDR (tail))
2592 { 2592 {
2593 Lisp_Object frame, bar, condemned; 2593 Lisp_Object frame, bar, condemned;
2594 2594
2595 frame = XCONS (tail)->car; 2595 frame = XCAR (tail);
2596 /* All elements of Vframe_list should be frames. */ 2596 /* All elements of Vframe_list should be frames. */
2597 if (! GC_FRAMEP (frame)) 2597 if (! GC_FRAMEP (frame))
2598 abort (); 2598 abort ();
@@ -3473,7 +3473,7 @@ w32_read_socket (sd, bufp, numchars, expected)
3473 numchars--; 3473 numchars--;
3474 } 3474 }
3475 else if (! NILP(Vframe_list) 3475 else if (! NILP(Vframe_list)
3476 && ! NILP (XCONS (Vframe_list)->cdr)) 3476 && ! NILP (XCDR (Vframe_list)))
3477 /* Force a redisplay sooner or later to update the 3477 /* Force a redisplay sooner or later to update the
3478 frame titles in case this is the second frame. */ 3478 frame titles in case this is the second frame. */
3479 record_asynch_buffer_change (); 3479 record_asynch_buffer_change ();
@@ -4981,7 +4981,7 @@ w32_term_init (display_name, xrm_option, resource_name)
4981 /* Put it on w32_display_name_list as well, to keep them parallel. */ 4981 /* Put it on w32_display_name_list as well, to keep them parallel. */
4982 w32_display_name_list = Fcons (Fcons (display_name, Qnil), 4982 w32_display_name_list = Fcons (Fcons (display_name, Qnil),
4983 w32_display_name_list); 4983 w32_display_name_list);
4984 dpyinfo->name_list_element = XCONS (w32_display_name_list)->car; 4984 dpyinfo->name_list_element = XCAR (w32_display_name_list);
4985 4985
4986 dpyinfo->w32_id_name 4986 dpyinfo->w32_id_name
4987 = (char *) xmalloc (XSTRING (Vinvocation_name)->size 4987 = (char *) xmalloc (XSTRING (Vinvocation_name)->size
@@ -5071,22 +5071,22 @@ x_delete_display (dpyinfo)
5071 /* Discard this display from w32_display_name_list and w32_display_list. 5071 /* Discard this display from w32_display_name_list and w32_display_list.
5072 We can't use Fdelq because that can quit. */ 5072 We can't use Fdelq because that can quit. */
5073 if (! NILP (w32_display_name_list) 5073 if (! NILP (w32_display_name_list)
5074 && EQ (XCONS (w32_display_name_list)->car, dpyinfo->name_list_element)) 5074 && EQ (XCAR (w32_display_name_list), dpyinfo->name_list_element))
5075 w32_display_name_list = XCONS (w32_display_name_list)->cdr; 5075 w32_display_name_list = XCDR (w32_display_name_list);
5076 else 5076 else
5077 { 5077 {
5078 Lisp_Object tail; 5078 Lisp_Object tail;
5079 5079
5080 tail = w32_display_name_list; 5080 tail = w32_display_name_list;
5081 while (CONSP (tail) && CONSP (XCONS (tail)->cdr)) 5081 while (CONSP (tail) && CONSP (XCDR (tail)))
5082 { 5082 {
5083 if (EQ (XCONS (XCONS (tail)->cdr)->car, 5083 if (EQ (XCAR (XCDR (tail)),
5084 dpyinfo->name_list_element)) 5084 dpyinfo->name_list_element))
5085 { 5085 {
5086 XCONS (tail)->cdr = XCONS (XCONS (tail)->cdr)->cdr; 5086 XCDR (tail) = XCDR (XCDR (tail));
5087 break; 5087 break;
5088 } 5088 }
5089 tail = XCONS (tail)->cdr; 5089 tail = XCDR (tail);
5090 } 5090 }
5091 } 5091 }
5092 5092
diff --git a/src/xfns.c b/src/xfns.c
index f994598ad1a..654b42f8b32 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -351,9 +351,9 @@ x_window_to_frame (dpyinfo, wdesc)
351 Lisp_Object tail, frame; 351 Lisp_Object tail, frame;
352 struct frame *f; 352 struct frame *f;
353 353
354 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 354 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
355 { 355 {
356 frame = XCONS (tail)->car; 356 frame = XCAR (tail);
357 if (!GC_FRAMEP (frame)) 357 if (!GC_FRAMEP (frame))
358 continue; 358 continue;
359 f = XFRAME (frame); 359 f = XFRAME (frame);
@@ -389,9 +389,9 @@ x_any_window_to_frame (dpyinfo, wdesc)
389 struct frame *f; 389 struct frame *f;
390 struct x_output *x; 390 struct x_output *x;
391 391
392 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 392 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
393 { 393 {
394 frame = XCONS (tail)->car; 394 frame = XCAR (tail);
395 if (!GC_FRAMEP (frame)) 395 if (!GC_FRAMEP (frame))
396 continue; 396 continue;
397 f = XFRAME (frame); 397 f = XFRAME (frame);
@@ -427,9 +427,9 @@ x_non_menubar_window_to_frame (dpyinfo, wdesc)
427 struct frame *f; 427 struct frame *f;
428 struct x_output *x; 428 struct x_output *x;
429 429
430 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 430 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
431 { 431 {
432 frame = XCONS (tail)->car; 432 frame = XCAR (tail);
433 if (!GC_FRAMEP (frame)) 433 if (!GC_FRAMEP (frame))
434 continue; 434 continue;
435 f = XFRAME (frame); 435 f = XFRAME (frame);
@@ -462,9 +462,9 @@ x_menubar_window_to_frame (dpyinfo, wdesc)
462 struct frame *f; 462 struct frame *f;
463 struct x_output *x; 463 struct x_output *x;
464 464
465 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 465 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
466 { 466 {
467 frame = XCONS (tail)->car; 467 frame = XCAR (tail);
468 if (!GC_FRAMEP (frame)) 468 if (!GC_FRAMEP (frame))
469 continue; 469 continue;
470 f = XFRAME (frame); 470 f = XFRAME (frame);
@@ -491,9 +491,9 @@ x_top_window_to_frame (dpyinfo, wdesc)
491 struct frame *f; 491 struct frame *f;
492 struct x_output *x; 492 struct x_output *x;
493 493
494 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 494 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
495 { 495 {
496 frame = XCONS (tail)->car; 496 frame = XCAR (tail);
497 if (!GC_FRAMEP (frame)) 497 if (!GC_FRAMEP (frame))
498 continue; 498 continue;
499 f = XFRAME (frame); 499 f = XFRAME (frame);
@@ -1027,18 +1027,18 @@ x_set_frame_parameters (f, alist)
1027 if (leftpos < 0) 1027 if (leftpos < 0)
1028 f->output_data.x->size_hint_flags |= XNegative; 1028 f->output_data.x->size_hint_flags |= XNegative;
1029 } 1029 }
1030 else if (CONSP (left) && EQ (XCONS (left)->car, Qminus) 1030 else if (CONSP (left) && EQ (XCAR (left), Qminus)
1031 && CONSP (XCONS (left)->cdr) 1031 && CONSP (XCDR (left))
1032 && INTEGERP (XCONS (XCONS (left)->cdr)->car)) 1032 && INTEGERP (XCAR (XCDR (left))))
1033 { 1033 {
1034 leftpos = - XINT (XCONS (XCONS (left)->cdr)->car); 1034 leftpos = - XINT (XCAR (XCDR (left)));
1035 f->output_data.x->size_hint_flags |= XNegative; 1035 f->output_data.x->size_hint_flags |= XNegative;
1036 } 1036 }
1037 else if (CONSP (left) && EQ (XCONS (left)->car, Qplus) 1037 else if (CONSP (left) && EQ (XCAR (left), Qplus)
1038 && CONSP (XCONS (left)->cdr) 1038 && CONSP (XCDR (left))
1039 && INTEGERP (XCONS (XCONS (left)->cdr)->car)) 1039 && INTEGERP (XCAR (XCDR (left))))
1040 { 1040 {
1041 leftpos = XINT (XCONS (XCONS (left)->cdr)->car); 1041 leftpos = XINT (XCAR (XCDR (left)));
1042 } 1042 }
1043 1043
1044 if (EQ (top, Qminus)) 1044 if (EQ (top, Qminus))
@@ -1049,18 +1049,18 @@ x_set_frame_parameters (f, alist)
1049 if (toppos < 0) 1049 if (toppos < 0)
1050 f->output_data.x->size_hint_flags |= YNegative; 1050 f->output_data.x->size_hint_flags |= YNegative;
1051 } 1051 }
1052 else if (CONSP (top) && EQ (XCONS (top)->car, Qminus) 1052 else if (CONSP (top) && EQ (XCAR (top), Qminus)
1053 && CONSP (XCONS (top)->cdr) 1053 && CONSP (XCDR (top))
1054 && INTEGERP (XCONS (XCONS (top)->cdr)->car)) 1054 && INTEGERP (XCAR (XCDR (top))))
1055 { 1055 {
1056 toppos = - XINT (XCONS (XCONS (top)->cdr)->car); 1056 toppos = - XINT (XCAR (XCDR (top)));
1057 f->output_data.x->size_hint_flags |= YNegative; 1057 f->output_data.x->size_hint_flags |= YNegative;
1058 } 1058 }
1059 else if (CONSP (top) && EQ (XCONS (top)->car, Qplus) 1059 else if (CONSP (top) && EQ (XCAR (top), Qplus)
1060 && CONSP (XCONS (top)->cdr) 1060 && CONSP (XCDR (top))
1061 && INTEGERP (XCONS (XCONS (top)->cdr)->car)) 1061 && INTEGERP (XCAR (XCDR (top))))
1062 { 1062 {
1063 toppos = XINT (XCONS (XCONS (top)->cdr)->car); 1063 toppos = XINT (XCAR (XCDR (top)));
1064 } 1064 }
1065 1065
1066 1066
@@ -1205,7 +1205,7 @@ x_report_frame_params (f, alistptr)
1205 (FRAME_VISIBLE_P (f) ? Qt 1205 (FRAME_VISIBLE_P (f) ? Qt
1206 : FRAME_ICONIFIED_P (f) ? Qicon : Qnil)); 1206 : FRAME_ICONIFIED_P (f) ? Qicon : Qnil));
1207 store_in_alist (alistptr, Qdisplay, 1207 store_in_alist (alistptr, Qdisplay,
1208 XCONS (FRAME_X_DISPLAY_INFO (f)->name_list_element)->car); 1208 XCAR (FRAME_X_DISPLAY_INFO (f)->name_list_element));
1209 1209
1210 if (f->output_data.x->parent_desc == FRAME_X_DISPLAY_INFO (f)->root_window) 1210 if (f->output_data.x->parent_desc == FRAME_X_DISPLAY_INFO (f)->root_window)
1211 tem = Qnil; 1211 tem = Qnil;
@@ -1698,11 +1698,11 @@ x_set_cursor_type (f, arg, oldval)
1698 FRAME_DESIRED_CURSOR (f) = BAR_CURSOR; 1698 FRAME_DESIRED_CURSOR (f) = BAR_CURSOR;
1699 f->output_data.x->cursor_width = 2; 1699 f->output_data.x->cursor_width = 2;
1700 } 1700 }
1701 else if (CONSP (arg) && EQ (XCONS (arg)->car, Qbar) 1701 else if (CONSP (arg) && EQ (XCAR (arg), Qbar)
1702 && INTEGERP (XCONS (arg)->cdr)) 1702 && INTEGERP (XCDR (arg)))
1703 { 1703 {
1704 FRAME_DESIRED_CURSOR (f) = BAR_CURSOR; 1704 FRAME_DESIRED_CURSOR (f) = BAR_CURSOR;
1705 f->output_data.x->cursor_width = XINT (XCONS (arg)->cdr); 1705 f->output_data.x->cursor_width = XINT (XCDR (arg));
1706 } 1706 }
1707 else 1707 else
1708 /* Treat anything unknown as "box cursor". 1708 /* Treat anything unknown as "box cursor".
@@ -1759,7 +1759,7 @@ x_icon_type (f)
1759 1759
1760 tem = assq_no_quit (Qicon_type, f->param_alist); 1760 tem = assq_no_quit (Qicon_type, f->param_alist);
1761 if (CONSP (tem)) 1761 if (CONSP (tem))
1762 return XCONS (tem)->cdr; 1762 return XCDR (tem);
1763 else 1763 else
1764 return Qnil; 1764 return Qnil;
1765} 1765}
@@ -2921,18 +2921,18 @@ x_figure_window_size (f, parms)
2921 f->output_data.x->top_pos = 0; 2921 f->output_data.x->top_pos = 0;
2922 window_prompting |= YNegative; 2922 window_prompting |= YNegative;
2923 } 2923 }
2924 else if (CONSP (tem0) && EQ (XCONS (tem0)->car, Qminus) 2924 else if (CONSP (tem0) && EQ (XCAR (tem0), Qminus)
2925 && CONSP (XCONS (tem0)->cdr) 2925 && CONSP (XCDR (tem0))
2926 && INTEGERP (XCONS (XCONS (tem0)->cdr)->car)) 2926 && INTEGERP (XCAR (XCDR (tem0))))
2927 { 2927 {
2928 f->output_data.x->top_pos = - XINT (XCONS (XCONS (tem0)->cdr)->car); 2928 f->output_data.x->top_pos = - XINT (XCAR (XCDR (tem0)));
2929 window_prompting |= YNegative; 2929 window_prompting |= YNegative;
2930 } 2930 }
2931 else if (CONSP (tem0) && EQ (XCONS (tem0)->car, Qplus) 2931 else if (CONSP (tem0) && EQ (XCAR (tem0), Qplus)
2932 && CONSP (XCONS (tem0)->cdr) 2932 && CONSP (XCDR (tem0))
2933 && INTEGERP (XCONS (XCONS (tem0)->cdr)->car)) 2933 && INTEGERP (XCAR (XCDR (tem0))))
2934 { 2934 {
2935 f->output_data.x->top_pos = XINT (XCONS (XCONS (tem0)->cdr)->car); 2935 f->output_data.x->top_pos = XINT (XCAR (XCDR (tem0)));
2936 } 2936 }
2937 else if (EQ (tem0, Qunbound)) 2937 else if (EQ (tem0, Qunbound))
2938 f->output_data.x->top_pos = 0; 2938 f->output_data.x->top_pos = 0;
@@ -2949,18 +2949,18 @@ x_figure_window_size (f, parms)
2949 f->output_data.x->left_pos = 0; 2949 f->output_data.x->left_pos = 0;
2950 window_prompting |= XNegative; 2950 window_prompting |= XNegative;
2951 } 2951 }
2952 else if (CONSP (tem1) && EQ (XCONS (tem1)->car, Qminus) 2952 else if (CONSP (tem1) && EQ (XCAR (tem1), Qminus)
2953 && CONSP (XCONS (tem1)->cdr) 2953 && CONSP (XCDR (tem1))
2954 && INTEGERP (XCONS (XCONS (tem1)->cdr)->car)) 2954 && INTEGERP (XCAR (XCDR (tem1))))
2955 { 2955 {
2956 f->output_data.x->left_pos = - XINT (XCONS (XCONS (tem1)->cdr)->car); 2956 f->output_data.x->left_pos = - XINT (XCAR (XCDR (tem1)));
2957 window_prompting |= XNegative; 2957 window_prompting |= XNegative;
2958 } 2958 }
2959 else if (CONSP (tem1) && EQ (XCONS (tem1)->car, Qplus) 2959 else if (CONSP (tem1) && EQ (XCAR (tem1), Qplus)
2960 && CONSP (XCONS (tem1)->cdr) 2960 && CONSP (XCDR (tem1))
2961 && INTEGERP (XCONS (XCONS (tem1)->cdr)->car)) 2961 && INTEGERP (XCAR (XCDR (tem1))))
2962 { 2962 {
2963 f->output_data.x->left_pos = XINT (XCONS (XCONS (tem1)->cdr)->car); 2963 f->output_data.x->left_pos = XINT (XCAR (XCDR (tem1)));
2964 } 2964 }
2965 else if (EQ (tem1, Qunbound)) 2965 else if (EQ (tem1, Qunbound))
2966 f->output_data.x->left_pos = 0; 2966 f->output_data.x->left_pos = 0;
@@ -3673,8 +3673,8 @@ This function is an internal primitive--use `make-frame' instead.")
3673 } 3673 }
3674 3674
3675 /* Create fontsets from `global_fontset_alist' before handling fonts. */ 3675 /* Create fontsets from `global_fontset_alist' before handling fonts. */
3676 for (tem = Vglobal_fontset_alist; CONSP (tem); tem = XCONS (tem)->cdr) 3676 for (tem = Vglobal_fontset_alist; CONSP (tem); tem = XCDR (tem))
3677 fs_register_fontset (f, XCONS (tem)->car); 3677 fs_register_fontset (f, XCAR (tem));
3678 3678
3679 /* Extract the window parameters from the supplied values 3679 /* Extract the window parameters from the supplied values
3680 that are needed to determine window geometry. */ 3680 that are needed to determine window geometry. */
@@ -5262,10 +5262,10 @@ x_display_info_for_name (name)
5262 5262
5263 for (dpyinfo = x_display_list, names = x_display_name_list; 5263 for (dpyinfo = x_display_list, names = x_display_name_list;
5264 dpyinfo; 5264 dpyinfo;
5265 dpyinfo = dpyinfo->next, names = XCONS (names)->cdr) 5265 dpyinfo = dpyinfo->next, names = XCDR (names))
5266 { 5266 {
5267 Lisp_Object tem; 5267 Lisp_Object tem;
5268 tem = Fstring_equal (XCONS (XCONS (names)->car)->car, name); 5268 tem = Fstring_equal (XCAR (XCAR (names)), name);
5269 if (!NILP (tem)) 5269 if (!NILP (tem))
5270 return dpyinfo; 5270 return dpyinfo;
5271 } 5271 }
@@ -5383,8 +5383,8 @@ DEFUN ("x-display-list", Fx_display_list, Sx_display_list, 0, 0, 0,
5383 Lisp_Object tail, result; 5383 Lisp_Object tail, result;
5384 5384
5385 result = Qnil; 5385 result = Qnil;
5386 for (tail = x_display_name_list; ! NILP (tail); tail = XCONS (tail)->cdr) 5386 for (tail = x_display_name_list; ! NILP (tail); tail = XCDR (tail))
5387 result = Fcons (XCONS (XCONS (tail)->car)->car, result); 5387 result = Fcons (XCAR (XCAR (tail)), result);
5388 5388
5389 return result; 5389 return result;
5390} 5390}
@@ -9591,8 +9591,8 @@ x_create_tip_frame (dpyinfo, parms)
9591 } 9591 }
9592 9592
9593 /* Create fontsets from `global_fontset_alist' before handling fonts. */ 9593 /* Create fontsets from `global_fontset_alist' before handling fonts. */
9594 for (tem = Vglobal_fontset_alist; CONSP (tem); tem = XCONS (tem)->cdr) 9594 for (tem = Vglobal_fontset_alist; CONSP (tem); tem = XCDR (tem))
9595 fs_register_fontset (f, XCONS (tem)->car); 9595 fs_register_fontset (f, XCAR (tem));
9596 9596
9597 /* Extract the window parameters from the supplied values 9597 /* Extract the window parameters from the supplied values
9598 that are needed to determine window geometry. */ 9598 that are needed to determine window geometry. */
diff --git a/src/xmenu.c b/src/xmenu.c
index 2e8776fb9f8..a671d4a76b6 100644
--- a/src/xmenu.c
+++ b/src/xmenu.c
@@ -211,9 +211,9 @@ menubar_id_to_frame (id)
211 Lisp_Object tail, frame; 211 Lisp_Object tail, frame;
212 FRAME_PTR f; 212 FRAME_PTR f;
213 213
214 for (tail = Vframe_list; GC_CONSP (tail); tail = XCONS (tail)->cdr) 214 for (tail = Vframe_list; GC_CONSP (tail); tail = XCDR (tail))
215 { 215 {
216 frame = XCONS (tail)->car; 216 frame = XCAR (tail);
217 if (!GC_FRAMEP (frame)) 217 if (!GC_FRAMEP (frame))
218 continue; 218 continue;
219 f = XFRAME (frame); 219 f = XFRAME (frame);
@@ -417,14 +417,14 @@ single_keymap_panes (keymap, pane_name, prefix, notreal, maxdepth)
417 notbuttons = menu_items_used; 417 notbuttons = menu_items_used;
418#endif 418#endif
419 419
420 for (tail = keymap; CONSP (tail); tail = XCONS (tail)->cdr) 420 for (tail = keymap; CONSP (tail); tail = XCDR (tail))
421 { 421 {
422 GCPRO2 (keymap, pending_maps); 422 GCPRO2 (keymap, pending_maps);
423 /* Look at each key binding, and if it is a menu item add it 423 /* Look at each key binding, and if it is a menu item add it
424 to this menu. */ 424 to this menu. */
425 item = XCONS (tail)->car; 425 item = XCAR (tail);
426 if (CONSP (item)) 426 if (CONSP (item))
427 single_menu_item (XCONS (item)->car, XCONS (item)->cdr, 427 single_menu_item (XCAR (item), XCDR (item),
428 &pending_maps, notreal, maxdepth, &notbuttons); 428 &pending_maps, notreal, maxdepth, &notbuttons);
429 else if (VECTORP (item)) 429 else if (VECTORP (item))
430 { 430 {
@@ -447,12 +447,12 @@ single_keymap_panes (keymap, pane_name, prefix, notreal, maxdepth)
447 { 447 {
448 Lisp_Object elt, eltcdr, string; 448 Lisp_Object elt, eltcdr, string;
449 elt = Fcar (pending_maps); 449 elt = Fcar (pending_maps);
450 eltcdr = XCONS (elt)->cdr; 450 eltcdr = XCDR (elt);
451 string = XCONS (eltcdr)->car; 451 string = XCAR (eltcdr);
452 /* We no longer discard the @ from the beginning of the string here. 452 /* We no longer discard the @ from the beginning of the string here.
453 Instead, we do this in xmenu_show. */ 453 Instead, we do this in xmenu_show. */
454 single_keymap_panes (Fcar (elt), string, 454 single_keymap_panes (Fcar (elt), string,
455 XCONS (eltcdr)->cdr, notreal, maxdepth - 1); 455 XCDR (eltcdr), notreal, maxdepth - 1);
456 pending_maps = Fcdr (pending_maps); 456 pending_maps = Fcdr (pending_maps);
457 } 457 }
458} 458}
@@ -705,7 +705,7 @@ cached information about equivalent key sequences.")
705 705
706 /* Decode the first argument: find the window and the coordinates. */ 706 /* Decode the first argument: find the window and the coordinates. */
707 if (EQ (position, Qt) 707 if (EQ (position, Qt)
708 || (CONSP (position) && EQ (XCONS (position)->car, Qmenu_bar))) 708 || (CONSP (position) && EQ (XCAR (position), Qmenu_bar)))
709 { 709 {
710 /* Use the mouse's current position. */ 710 /* Use the mouse's current position. */
711 FRAME_PTR new_f = selected_frame; 711 FRAME_PTR new_f = selected_frame;
@@ -903,7 +903,7 @@ on the left of the dialog box and all following items on the right.\n\
903 903
904 /* Decode the first argument: find the window or frame to use. */ 904 /* Decode the first argument: find the window or frame to use. */
905 if (EQ (position, Qt) 905 if (EQ (position, Qt)
906 || (CONSP (position) && EQ (XCONS (position)->car, Qmenu_bar))) 906 || (CONSP (position) && EQ (XCAR (position), Qmenu_bar)))
907 { 907 {
908#if 0 /* Using the frame the mouse is on may not be right. */ 908#if 0 /* Using the frame the mouse is on may not be right. */
909 /* Use the mouse's current position. */ 909 /* Use the mouse's current position. */
diff --git a/src/xselect.c b/src/xselect.c
index 6219483eac7..ba7b7063f9c 100644
--- a/src/xselect.c
+++ b/src/xselect.c
@@ -278,9 +278,9 @@ x_own_selection (selection_name, selection_value)
278 { 278 {
279 Lisp_Object rest; /* we know it's not the CAR, so it's easy. */ 279 Lisp_Object rest; /* we know it's not the CAR, so it's easy. */
280 for (rest = Vselection_alist; !NILP (rest); rest = Fcdr (rest)) 280 for (rest = Vselection_alist; !NILP (rest); rest = Fcdr (rest))
281 if (EQ (prev_value, Fcar (XCONS (rest)->cdr))) 281 if (EQ (prev_value, Fcar (XCDR (rest))))
282 { 282 {
283 XCONS (rest)->cdr = Fcdr (XCONS (rest)->cdr); 283 XCDR (rest) = Fcdr (XCDR (rest));
284 break; 284 break;
285 } 285 }
286 } 286 }
@@ -311,7 +311,7 @@ x_get_local_selection (selection_symbol, target_type)
311 if (EQ (target_type, QTIMESTAMP)) 311 if (EQ (target_type, QTIMESTAMP))
312 { 312 {
313 handler_fn = Qnil; 313 handler_fn = Qnil;
314 value = XCONS (XCONS (XCONS (local_value)->cdr)->cdr)->car; 314 value = XCAR (XCDR (XCDR (local_value)));
315 } 315 }
316#if 0 316#if 0
317 else if (EQ (target_type, QDELETE)) 317 else if (EQ (target_type, QDELETE))
@@ -319,19 +319,19 @@ x_get_local_selection (selection_symbol, target_type)
319 handler_fn = Qnil; 319 handler_fn = Qnil;
320 Fx_disown_selection_internal 320 Fx_disown_selection_internal
321 (selection_symbol, 321 (selection_symbol,
322 XCONS (XCONS (XCONS (local_value)->cdr)->cdr)->car); 322 XCAR (XCDR (XCDR (local_value))));
323 value = QNULL; 323 value = QNULL;
324 } 324 }
325#endif 325#endif
326 326
327#if 0 /* #### MULTIPLE doesn't work yet */ 327#if 0 /* #### MULTIPLE doesn't work yet */
328 else if (CONSP (target_type) 328 else if (CONSP (target_type)
329 && XCONS (target_type)->car == QMULTIPLE) 329 && XCAR (target_type) == QMULTIPLE)
330 { 330 {
331 Lisp_Object pairs; 331 Lisp_Object pairs;
332 int size; 332 int size;
333 int i; 333 int i;
334 pairs = XCONS (target_type)->cdr; 334 pairs = XCDR (target_type);
335 size = XVECTOR (pairs)->size; 335 size = XVECTOR (pairs)->size;
336 /* If the target is MULTIPLE, then target_type looks like 336 /* If the target is MULTIPLE, then target_type looks like
337 (MULTIPLE . [[SELECTION1 TARGET1] [SELECTION2 TARGET2] ... ]) 337 (MULTIPLE . [[SELECTION1 TARGET1] [SELECTION2 TARGET2] ... ])
@@ -362,7 +362,7 @@ x_get_local_selection (selection_symbol, target_type)
362 if (!NILP (handler_fn)) 362 if (!NILP (handler_fn))
363 value = call3 (handler_fn, 363 value = call3 (handler_fn,
364 selection_symbol, target_type, 364 selection_symbol, target_type,
365 XCONS (XCONS (local_value)->cdr)->car); 365 XCAR (XCDR (local_value)));
366 else 366 else
367 value = Qnil; 367 value = Qnil;
368 unbind_to (count, Qnil); 368 unbind_to (count, Qnil);
@@ -373,9 +373,9 @@ x_get_local_selection (selection_symbol, target_type)
373 373
374 check = value; 374 check = value;
375 if (CONSP (value) 375 if (CONSP (value)
376 && SYMBOLP (XCONS (value)->car)) 376 && SYMBOLP (XCAR (value)))
377 type = XCONS (value)->car, 377 type = XCAR (value),
378 check = XCONS (value)->cdr; 378 check = XCDR (value);
379 379
380 if (STRINGP (check) 380 if (STRINGP (check)
381 || VECTORP (check) 381 || VECTORP (check)
@@ -385,12 +385,12 @@ x_get_local_selection (selection_symbol, target_type)
385 return value; 385 return value;
386 /* Check for a value that cons_to_long could handle. */ 386 /* Check for a value that cons_to_long could handle. */
387 else if (CONSP (check) 387 else if (CONSP (check)
388 && INTEGERP (XCONS (check)->car) 388 && INTEGERP (XCAR (check))
389 && (INTEGERP (XCONS (check)->cdr) 389 && (INTEGERP (XCDR (check))
390 || 390 ||
391 (CONSP (XCONS (check)->cdr) 391 (CONSP (XCDR (check))
392 && INTEGERP (XCONS (XCONS (check)->cdr)->car) 392 && INTEGERP (XCAR (XCDR (check)))
393 && NILP (XCONS (XCONS (check)->cdr)->cdr)))) 393 && NILP (XCDR (XCDR (check))))))
394 return value; 394 return value;
395 else 395 else
396 return 396 return
@@ -687,7 +687,7 @@ x_handle_selection_request (event)
687 } 687 }
688 688
689 local_selection_time = (Time) 689 local_selection_time = (Time)
690 cons_to_long (XCONS (XCONS (XCONS (local_selection_data)->cdr)->cdr)->car); 690 cons_to_long (XCAR (XCDR (XCDR (local_selection_data))));
691 691
692 if (SELECTION_EVENT_TIME (event) != CurrentTime 692 if (SELECTION_EVENT_TIME (event) != CurrentTime
693 && local_selection_time > SELECTION_EVENT_TIME (event)) 693 && local_selection_time > SELECTION_EVENT_TIME (event))
@@ -799,7 +799,7 @@ x_handle_selection_clear (event)
799 if (NILP (local_selection_data)) return; 799 if (NILP (local_selection_data)) return;
800 800
801 local_selection_time = (Time) 801 local_selection_time = (Time)
802 cons_to_long (XCONS (XCONS (XCONS (local_selection_data)->cdr)->cdr)->car); 802 cons_to_long (XCAR (XCDR (XCDR (local_selection_data))));
803 803
804 /* This SelectionClear is for a selection that we no longer own, so we can 804 /* This SelectionClear is for a selection that we no longer own, so we can
805 disregard it. (That is, we have reasserted the selection since this 805 disregard it. (That is, we have reasserted the selection since this
@@ -818,9 +818,9 @@ x_handle_selection_clear (event)
818 { 818 {
819 Lisp_Object rest; 819 Lisp_Object rest;
820 for (rest = Vselection_alist; !NILP (rest); rest = Fcdr (rest)) 820 for (rest = Vselection_alist; !NILP (rest); rest = Fcdr (rest))
821 if (EQ (local_selection_data, Fcar (XCONS (rest)->cdr))) 821 if (EQ (local_selection_data, Fcar (XCDR (rest))))
822 { 822 {
823 XCONS (rest)->cdr = Fcdr (XCONS (rest)->cdr); 823 XCDR (rest) = Fcdr (XCDR (rest));
824 break; 824 break;
825 } 825 }
826 } 826 }
@@ -881,13 +881,13 @@ x_clear_frame_selections (f)
881 881
882 /* Delete elements after the beginning of Vselection_alist. */ 882 /* Delete elements after the beginning of Vselection_alist. */
883 for (rest = Vselection_alist; !NILP (rest); rest = Fcdr (rest)) 883 for (rest = Vselection_alist; !NILP (rest); rest = Fcdr (rest))
884 if (EQ (frame, Fcar (Fcdr (Fcdr (Fcdr (Fcar (XCONS (rest)->cdr))))))) 884 if (EQ (frame, Fcar (Fcdr (Fcdr (Fcdr (Fcar (XCDR (rest))))))))
885 { 885 {
886 /* Let random Lisp code notice that the selection has been stolen. */ 886 /* Let random Lisp code notice that the selection has been stolen. */
887 Lisp_Object hooks, selection_symbol; 887 Lisp_Object hooks, selection_symbol;
888 888
889 hooks = Vx_lost_selection_hooks; 889 hooks = Vx_lost_selection_hooks;
890 selection_symbol = Fcar (Fcar (XCONS (rest)->cdr)); 890 selection_symbol = Fcar (Fcar (XCDR (rest)));
891 891
892 if (!EQ (hooks, Qunbound)) 892 if (!EQ (hooks, Qunbound))
893 { 893 {
@@ -897,7 +897,7 @@ x_clear_frame_selections (f)
897 redisplay_preserve_echo_area (); 897 redisplay_preserve_echo_area ();
898#endif 898#endif
899 } 899 }
900 XCONS (rest)->cdr = Fcdr (XCONS (rest)->cdr); 900 XCDR (rest) = Fcdr (XCDR (rest));
901 break; 901 break;
902 } 902 }
903} 903}
@@ -975,8 +975,8 @@ wait_for_property_change_unwind (identifierval)
975 Lisp_Object identifierval; 975 Lisp_Object identifierval;
976{ 976{
977 unexpect_property_change ((struct prop_location *) 977 unexpect_property_change ((struct prop_location *)
978 (XFASTINT (XCONS (identifierval)->car) << 16 978 (XFASTINT (XCAR (identifierval)) << 16
979 | XFASTINT (XCONS (identifierval)->cdr))); 979 | XFASTINT (XCDR (identifierval))));
980 return Qnil; 980 return Qnil;
981} 981}
982 982
@@ -992,13 +992,13 @@ wait_for_property_change (location)
992 Lisp_Object tem; 992 Lisp_Object tem;
993 993
994 tem = Fcons (Qnil, Qnil); 994 tem = Fcons (Qnil, Qnil);
995 XSETFASTINT (XCONS (tem)->car, (EMACS_UINT)location >> 16); 995 XSETFASTINT (XCAR (tem), (EMACS_UINT)location >> 16);
996 XSETFASTINT (XCONS (tem)->cdr, (EMACS_UINT)location & 0xffff); 996 XSETFASTINT (XCDR (tem), (EMACS_UINT)location & 0xffff);
997 997
998 /* Make sure to do unexpect_property_change if we quit or err. */ 998 /* Make sure to do unexpect_property_change if we quit or err. */
999 record_unwind_protect (wait_for_property_change_unwind, tem); 999 record_unwind_protect (wait_for_property_change_unwind, tem);
1000 1000
1001 XCONS (property_change_reply)->car = Qnil; 1001 XCAR (property_change_reply) = Qnil;
1002 1002
1003 property_change_reply_object = location; 1003 property_change_reply_object = location;
1004 /* If the event we are waiting for arrives beyond here, it will set 1004 /* If the event we are waiting for arrives beyond here, it will set
@@ -1009,7 +1009,7 @@ wait_for_property_change (location)
1009 usecs = (x_selection_timeout % 1000) * 1000; 1009 usecs = (x_selection_timeout % 1000) * 1000;
1010 wait_reading_process_input (secs, usecs, property_change_reply, 0); 1010 wait_reading_process_input (secs, usecs, property_change_reply, 0);
1011 1011
1012 if (NILP (XCONS (property_change_reply)->car)) 1012 if (NILP (XCAR (property_change_reply)))
1013 error ("Timed out waiting for property-notify event"); 1013 error ("Timed out waiting for property-notify event");
1014 } 1014 }
1015 1015
@@ -1043,7 +1043,7 @@ x_handle_property_notify (event)
1043 /* If this is the one wait_for_property_change is waiting for, 1043 /* If this is the one wait_for_property_change is waiting for,
1044 tell it to wake up. */ 1044 tell it to wake up. */
1045 if (rest == property_change_reply_object) 1045 if (rest == property_change_reply_object)
1046 XCONS (property_change_reply)->car = Qt; 1046 XCAR (property_change_reply) = Qt;
1047 1047
1048 if (prev) 1048 if (prev)
1049 prev->next = rest->next; 1049 prev->next = rest->next;
@@ -1092,7 +1092,7 @@ copy_multiple_data (obj)
1092 int i; 1092 int i;
1093 int size; 1093 int size;
1094 if (CONSP (obj)) 1094 if (CONSP (obj))
1095 return Fcons (XCONS (obj)->car, copy_multiple_data (XCONS (obj)->cdr)); 1095 return Fcons (XCAR (obj), copy_multiple_data (XCDR (obj)));
1096 1096
1097 CHECK_VECTOR (obj, 0); 1097 CHECK_VECTOR (obj, 0);
1098 vec = Fmake_vector (size = XVECTOR (obj)->size, Qnil); 1098 vec = Fmake_vector (size = XVECTOR (obj)->size, Qnil);
@@ -1140,7 +1140,7 @@ x_get_foreign_selection (selection_symbol, target_type)
1140 Lisp_Object frame; 1140 Lisp_Object frame;
1141 1141
1142 if (CONSP (target_type)) 1142 if (CONSP (target_type))
1143 type_atom = symbol_to_x_atom (dpyinfo, display, XCONS (target_type)->car); 1143 type_atom = symbol_to_x_atom (dpyinfo, display, XCAR (target_type));
1144 else 1144 else
1145 type_atom = symbol_to_x_atom (dpyinfo, display, target_type); 1145 type_atom = symbol_to_x_atom (dpyinfo, display, target_type);
1146 1146
@@ -1153,7 +1153,7 @@ x_get_foreign_selection (selection_symbol, target_type)
1153 /* Prepare to block until the reply has been read. */ 1153 /* Prepare to block until the reply has been read. */
1154 reading_selection_window = requestor_window; 1154 reading_selection_window = requestor_window;
1155 reading_which_selection = selection_atom; 1155 reading_which_selection = selection_atom;
1156 XCONS (reading_selection_reply)->car = Qnil; 1156 XCAR (reading_selection_reply) = Qnil;
1157 1157
1158 frame = some_frame_on_display (dpyinfo); 1158 frame = some_frame_on_display (dpyinfo);
1159 1159
@@ -1179,9 +1179,9 @@ x_get_foreign_selection (selection_symbol, target_type)
1179 x_uncatch_errors (display, count); 1179 x_uncatch_errors (display, count);
1180 UNBLOCK_INPUT; 1180 UNBLOCK_INPUT;
1181 1181
1182 if (NILP (XCONS (reading_selection_reply)->car)) 1182 if (NILP (XCAR (reading_selection_reply)))
1183 error ("Timed out waiting for reply from selection owner"); 1183 error ("Timed out waiting for reply from selection owner");
1184 if (EQ (XCONS (reading_selection_reply)->car, Qlambda)) 1184 if (EQ (XCAR (reading_selection_reply), Qlambda))
1185 error ("No `%s' selection", XSYMBOL (selection_symbol)->name->data); 1185 error ("No `%s' selection", XSYMBOL (selection_symbol)->name->data);
1186 1186
1187 /* Otherwise, the selection is waiting for us on the requested property. */ 1187 /* Otherwise, the selection is waiting for us on the requested property. */
@@ -1627,12 +1627,12 @@ lisp_data_to_selection_data (display, obj,
1627 1627
1628 *nofree_ret = 0; 1628 *nofree_ret = 0;
1629 1629
1630 if (CONSP (obj) && SYMBOLP (XCONS (obj)->car)) 1630 if (CONSP (obj) && SYMBOLP (XCAR (obj)))
1631 { 1631 {
1632 type = XCONS (obj)->car; 1632 type = XCAR (obj);
1633 obj = XCONS (obj)->cdr; 1633 obj = XCDR (obj);
1634 if (CONSP (obj) && NILP (XCONS (obj)->cdr)) 1634 if (CONSP (obj) && NILP (XCDR (obj)))
1635 obj = XCONS (obj)->car; 1635 obj = XCAR (obj);
1636 } 1636 }
1637 1637
1638 if (EQ (obj, QNULL) || (EQ (type, QNULL))) 1638 if (EQ (obj, QNULL) || (EQ (type, QNULL)))
@@ -1722,10 +1722,10 @@ lisp_data_to_selection_data (display, obj,
1722 if (NILP (type)) type = QINTEGER; 1722 if (NILP (type)) type = QINTEGER;
1723 } 1723 }
1724 else if (INTEGERP (obj) 1724 else if (INTEGERP (obj)
1725 || (CONSP (obj) && INTEGERP (XCONS (obj)->car) 1725 || (CONSP (obj) && INTEGERP (XCAR (obj))
1726 && (INTEGERP (XCONS (obj)->cdr) 1726 && (INTEGERP (XCDR (obj))
1727 || (CONSP (XCONS (obj)->cdr) 1727 || (CONSP (XCDR (obj))
1728 && INTEGERP (XCONS (XCONS (obj)->cdr)->car))))) 1728 && INTEGERP (XCAR (XCDR (obj)))))))
1729 { 1729 {
1730 *format_ret = 32; 1730 *format_ret = 32;
1731 *size_ret = 1; 1731 *size_ret = 1;
@@ -1831,20 +1831,20 @@ clean_local_selection_data (obj)
1831 Lisp_Object obj; 1831 Lisp_Object obj;
1832{ 1832{
1833 if (CONSP (obj) 1833 if (CONSP (obj)
1834 && INTEGERP (XCONS (obj)->car) 1834 && INTEGERP (XCAR (obj))
1835 && CONSP (XCONS (obj)->cdr) 1835 && CONSP (XCDR (obj))
1836 && INTEGERP (XCONS (XCONS (obj)->cdr)->car) 1836 && INTEGERP (XCAR (XCDR (obj)))
1837 && NILP (XCONS (XCONS (obj)->cdr)->cdr)) 1837 && NILP (XCDR (XCDR (obj))))
1838 obj = Fcons (XCONS (obj)->car, XCONS (obj)->cdr); 1838 obj = Fcons (XCAR (obj), XCDR (obj));
1839 1839
1840 if (CONSP (obj) 1840 if (CONSP (obj)
1841 && INTEGERP (XCONS (obj)->car) 1841 && INTEGERP (XCAR (obj))
1842 && INTEGERP (XCONS (obj)->cdr)) 1842 && INTEGERP (XCDR (obj)))
1843 { 1843 {
1844 if (XINT (XCONS (obj)->car) == 0) 1844 if (XINT (XCAR (obj)) == 0)
1845 return XCONS (obj)->cdr; 1845 return XCDR (obj);
1846 if (XINT (XCONS (obj)->car) == -1) 1846 if (XINT (XCAR (obj)) == -1)
1847 return make_number (- XINT (XCONS (obj)->cdr)); 1847 return make_number (- XINT (XCDR (obj)));
1848 } 1848 }
1849 if (VECTORP (obj)) 1849 if (VECTORP (obj))
1850 { 1850 {
@@ -1876,7 +1876,7 @@ x_handle_selection_notify (event)
1876 if (event->selection != reading_which_selection) 1876 if (event->selection != reading_which_selection)
1877 return; 1877 return;
1878 1878
1879 XCONS (reading_selection_reply)->car 1879 XCAR (reading_selection_reply)
1880 = (event->property != 0 ? Qt : Qlambda); 1880 = (event->property != 0 ? Qt : Qlambda);
1881} 1881}
1882 1882
@@ -1920,9 +1920,9 @@ TYPE is the type of data desired, typically `STRING'.")
1920 1920
1921#if 0 /* #### MULTIPLE doesn't work yet */ 1921#if 0 /* #### MULTIPLE doesn't work yet */
1922 if (CONSP (target_type) 1922 if (CONSP (target_type)
1923 && XCONS (target_type)->car == QMULTIPLE) 1923 && XCAR (target_type) == QMULTIPLE)
1924 { 1924 {
1925 CHECK_VECTOR (XCONS (target_type)->cdr, 0); 1925 CHECK_VECTOR (XCDR (target_type), 0);
1926 /* So we don't destructively modify this... */ 1926 /* So we don't destructively modify this... */
1927 target_type = copy_multiple_data (target_type); 1927 target_type = copy_multiple_data (target_type);
1928 } 1928 }
@@ -1939,11 +1939,11 @@ TYPE is the type of data desired, typically `STRING'.")
1939 } 1939 }
1940 1940
1941 if (CONSP (val) 1941 if (CONSP (val)
1942 && SYMBOLP (XCONS (val)->car)) 1942 && SYMBOLP (XCAR (val)))
1943 { 1943 {
1944 val = XCONS (val)->cdr; 1944 val = XCDR (val);
1945 if (CONSP (val) && NILP (XCONS (val)->cdr)) 1945 if (CONSP (val) && NILP (XCDR (val)))
1946 val = XCONS (val)->car; 1946 val = XCAR (val);
1947 } 1947 }
1948 val = clean_local_selection_data (val); 1948 val = clean_local_selection_data (val);
1949 DONE: 1949 DONE:
@@ -2006,14 +2006,14 @@ x_disown_buffer_selections (buffer)
2006 Lisp_Object tail; 2006 Lisp_Object tail;
2007 struct buffer *buf = XBUFFER (buffer); 2007 struct buffer *buf = XBUFFER (buffer);
2008 2008
2009 for (tail = Vselection_alist; CONSP (tail); tail = XCONS (tail)->cdr) 2009 for (tail = Vselection_alist; CONSP (tail); tail = XCDR (tail))
2010 { 2010 {
2011 Lisp_Object elt, value; 2011 Lisp_Object elt, value;
2012 elt = XCONS (tail)->car; 2012 elt = XCAR (tail);
2013 value = XCONS (elt)->cdr; 2013 value = XCDR (elt);
2014 if (CONSP (value) && MARKERP (XCONS (value)->car) 2014 if (CONSP (value) && MARKERP (XCAR (value))
2015 && XMARKER (XCONS (value)->car)->buffer == buf) 2015 && XMARKER (XCAR (value))->buffer == buf)
2016 Fx_disown_selection_internal (XCONS (elt)->car, Qnil); 2016 Fx_disown_selection_internal (XCAR (elt), Qnil);
2017 } 2017 }
2018} 2018}
2019 2019
diff --git a/src/xterm.c b/src/xterm.c
index 793e0098879..db2b3559a7c 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -7062,11 +7062,11 @@ x_window_to_scroll_bar (window_id)
7062 7062
7063 for (tail = Vframe_list; 7063 for (tail = Vframe_list;
7064 XGCTYPE (tail) == Lisp_Cons; 7064 XGCTYPE (tail) == Lisp_Cons;
7065 tail = XCONS (tail)->cdr) 7065 tail = XCDR (tail))
7066 { 7066 {
7067 Lisp_Object frame, bar, condemned; 7067 Lisp_Object frame, bar, condemned;
7068 7068
7069 frame = XCONS (tail)->car; 7069 frame = XCAR (tail);
7070 /* All elements of Vframe_list should be frames. */ 7070 /* All elements of Vframe_list should be frames. */
7071 if (! GC_FRAMEP (frame)) 7071 if (! GC_FRAMEP (frame))
7072 abort (); 7072 abort ();
@@ -9061,7 +9061,7 @@ XTread_socket (sd, bufp, numchars, expected)
9061 numchars--; 9061 numchars--;
9062 } 9062 }
9063 else if (! NILP (Vframe_list) 9063 else if (! NILP (Vframe_list)
9064 && ! NILP (XCONS (Vframe_list)->cdr)) 9064 && ! NILP (XCDR (Vframe_list)))
9065 /* Force a redisplay sooner or later 9065 /* Force a redisplay sooner or later
9066 to update the frame titles 9066 to update the frame titles
9067 in case this is the second frame. */ 9067 in case this is the second frame. */
@@ -11728,17 +11728,17 @@ x_list_fonts (f, pattern, size, maxnames)
11728 /* We can return any single font matching PATTERN. */ 11728 /* We can return any single font matching PATTERN. */
11729 try_XLoadQueryFont = 1; 11729 try_XLoadQueryFont = 1;
11730 11730
11731 for (; CONSP (patterns); patterns = XCONS (patterns)->cdr) 11731 for (; CONSP (patterns); patterns = XCDR (patterns))
11732 { 11732 {
11733 int num_fonts; 11733 int num_fonts;
11734 char **names; 11734 char **names;
11735 11735
11736 pattern = XCONS (patterns)->car; 11736 pattern = XCAR (patterns);
11737 /* See if we cached the result for this particular query. 11737 /* See if we cached the result for this particular query.
11738 The cache is an alist of the form: 11738 The cache is an alist of the form:
11739 (((PATTERN . MAXNAMES) (FONTNAME . WIDTH) ...) ...) 11739 (((PATTERN . MAXNAMES) (FONTNAME . WIDTH) ...) ...)
11740 */ 11740 */
11741 if (f && (tem = XCONS (FRAME_X_DISPLAY_INFO (f)->name_list_element)->cdr, 11741 if (f && (tem = XCDR (FRAME_X_DISPLAY_INFO (f)->name_list_element),
11742 key = Fcons (pattern, make_number (maxnames)), 11742 key = Fcons (pattern, make_number (maxnames)),
11743 !NILP (list = Fassoc (key, tem)))) 11743 !NILP (list = Fassoc (key, tem))))
11744 { 11744 {
@@ -11864,30 +11864,30 @@ x_list_fonts (f, pattern, size, maxnames)
11864 11864
11865 /* Now store the result in the cache. */ 11865 /* Now store the result in the cache. */
11866 if (f != NULL) 11866 if (f != NULL)
11867 XCONS (FRAME_X_DISPLAY_INFO (f)->name_list_element)->cdr 11867 XCDR (FRAME_X_DISPLAY_INFO (f)->name_list_element)
11868 = Fcons (Fcons (key, list), 11868 = Fcons (Fcons (key, list),
11869 XCONS (FRAME_X_DISPLAY_INFO (f)->name_list_element)->cdr); 11869 XCDR (FRAME_X_DISPLAY_INFO (f)->name_list_element));
11870 11870
11871 label_cached: 11871 label_cached:
11872 if (NILP (list)) continue; /* Try the remaining alternatives. */ 11872 if (NILP (list)) continue; /* Try the remaining alternatives. */
11873 11873
11874 newlist = second_best = Qnil; 11874 newlist = second_best = Qnil;
11875 /* Make a list of the fonts that have the right width. */ 11875 /* Make a list of the fonts that have the right width. */
11876 for (; CONSP (list); list = XCONS (list)->cdr) 11876 for (; CONSP (list); list = XCDR (list))
11877 { 11877 {
11878 int found_size; 11878 int found_size;
11879 11879
11880 tem = XCONS (list)->car; 11880 tem = XCAR (list);
11881 11881
11882 if (!CONSP (tem) || NILP (XCONS (tem)->car)) 11882 if (!CONSP (tem) || NILP (XCAR (tem)))
11883 continue; 11883 continue;
11884 if (!size) 11884 if (!size)
11885 { 11885 {
11886 newlist = Fcons (XCONS (tem)->car, newlist); 11886 newlist = Fcons (XCAR (tem), newlist);
11887 continue; 11887 continue;
11888 } 11888 }
11889 11889
11890 if (!INTEGERP (XCONS (tem)->cdr)) 11890 if (!INTEGERP (XCDR (tem)))
11891 { 11891 {
11892 /* Since we have not yet known the size of this font, we 11892 /* Since we have not yet known the size of this font, we
11893 must try slow function call XLoadQueryFont. */ 11893 must try slow function call XLoadQueryFont. */
@@ -11896,7 +11896,7 @@ x_list_fonts (f, pattern, size, maxnames)
11896 BLOCK_INPUT; 11896 BLOCK_INPUT;
11897 count = x_catch_errors (dpy); 11897 count = x_catch_errors (dpy);
11898 thisinfo = XLoadQueryFont (dpy, 11898 thisinfo = XLoadQueryFont (dpy,
11899 XSTRING (XCONS (tem)->car)->data); 11899 XSTRING (XCAR (tem))->data);
11900 if (x_had_errors_p (dpy)) 11900 if (x_had_errors_p (dpy))
11901 { 11901 {
11902 /* This error is perhaps due to insufficient memory on X 11902 /* This error is perhaps due to insufficient memory on X
@@ -11909,7 +11909,7 @@ x_list_fonts (f, pattern, size, maxnames)
11909 11909
11910 if (thisinfo) 11910 if (thisinfo)
11911 { 11911 {
11912 XCONS (tem)->cdr 11912 XCDR (tem)
11913 = (thisinfo->min_bounds.width == 0 11913 = (thisinfo->min_bounds.width == 0
11914 ? make_number (0) 11914 ? make_number (0)
11915 : make_number (thisinfo->max_bounds.width)); 11915 : make_number (thisinfo->max_bounds.width));
@@ -11919,26 +11919,26 @@ x_list_fonts (f, pattern, size, maxnames)
11919 /* For unknown reason, the previous call of XListFont had 11919 /* For unknown reason, the previous call of XListFont had
11920 returned a font which can't be opened. Record the size 11920 returned a font which can't be opened. Record the size
11921 as 0 not to try to open it again. */ 11921 as 0 not to try to open it again. */
11922 XCONS (tem)->cdr = make_number (0); 11922 XCDR (tem) = make_number (0);
11923 } 11923 }
11924 11924
11925 found_size = XINT (XCONS (tem)->cdr); 11925 found_size = XINT (XCDR (tem));
11926 if (found_size == size) 11926 if (found_size == size)
11927 newlist = Fcons (XCONS (tem)->car, newlist); 11927 newlist = Fcons (XCAR (tem), newlist);
11928 else if (found_size > 0) 11928 else if (found_size > 0)
11929 { 11929 {
11930 if (NILP (second_best)) 11930 if (NILP (second_best))
11931 second_best = tem; 11931 second_best = tem;
11932 else if (found_size < size) 11932 else if (found_size < size)
11933 { 11933 {
11934 if (XINT (XCONS (second_best)->cdr) > size 11934 if (XINT (XCDR (second_best)) > size
11935 || XINT (XCONS (second_best)->cdr) < found_size) 11935 || XINT (XCDR (second_best)) < found_size)
11936 second_best = tem; 11936 second_best = tem;
11937 } 11937 }
11938 else 11938 else
11939 { 11939 {
11940 if (XINT (XCONS (second_best)->cdr) > size 11940 if (XINT (XCDR (second_best)) > size
11941 && XINT (XCONS (second_best)->cdr) > found_size) 11941 && XINT (XCDR (second_best)) > found_size)
11942 second_best = tem; 11942 second_best = tem;
11943 } 11943 }
11944 } 11944 }
@@ -11947,7 +11947,7 @@ x_list_fonts (f, pattern, size, maxnames)
11947 break; 11947 break;
11948 else if (!NILP (second_best)) 11948 else if (!NILP (second_best))
11949 { 11949 {
11950 newlist = Fcons (XCONS (second_best)->car, Qnil); 11950 newlist = Fcons (XCAR (second_best), Qnil);
11951 break; 11951 break;
11952 } 11952 }
11953 } 11953 }
@@ -12071,12 +12071,12 @@ x_load_font (f, fontname, size)
12071 int i; 12071 int i;
12072 12072
12073 for (i = 0; i < dpyinfo->n_fonts; i++) 12073 for (i = 0; i < dpyinfo->n_fonts; i++)
12074 for (tail = font_names; CONSP (tail); tail = XCONS (tail)->cdr) 12074 for (tail = font_names; CONSP (tail); tail = XCDR (tail))
12075 if (dpyinfo->font_table[i].name 12075 if (dpyinfo->font_table[i].name
12076 && (!strcmp (dpyinfo->font_table[i].name, 12076 && (!strcmp (dpyinfo->font_table[i].name,
12077 XSTRING (XCONS (tail)->car)->data) 12077 XSTRING (XCAR (tail))->data)
12078 || !strcmp (dpyinfo->font_table[i].full_name, 12078 || !strcmp (dpyinfo->font_table[i].full_name,
12079 XSTRING (XCONS (tail)->car)->data))) 12079 XSTRING (XCAR (tail))->data)))
12080 return (dpyinfo->font_table + i); 12080 return (dpyinfo->font_table + i);
12081 } 12081 }
12082 12082
@@ -12094,7 +12094,7 @@ x_load_font (f, fontname, size)
12094 a bug of not finding a font even if the font surely exists and 12094 a bug of not finding a font even if the font surely exists and
12095 is loadable by XLoadQueryFont. */ 12095 is loadable by XLoadQueryFont. */
12096 if (size > 0 && !NILP (font_names)) 12096 if (size > 0 && !NILP (font_names))
12097 fontname = (char *) XSTRING (XCONS (font_names)->car)->data; 12097 fontname = (char *) XSTRING (XCAR (font_names))->data;
12098 12098
12099 BLOCK_INPUT; 12099 BLOCK_INPUT;
12100 count = x_catch_errors (FRAME_X_DISPLAY (f)); 12100 count = x_catch_errors (FRAME_X_DISPLAY (f));
@@ -12190,19 +12190,19 @@ x_load_font (f, fontname, size)
12190 Lisp_Object lispy_name = build_string (fontname); 12190 Lisp_Object lispy_name = build_string (fontname);
12191 Lisp_Object lispy_full_name = build_string (fontp->full_name); 12191 Lisp_Object lispy_full_name = build_string (fontp->full_name);
12192 12192
12193 XCONS (dpyinfo->name_list_element)->cdr 12193 XCDR (dpyinfo->name_list_element)
12194 = Fcons (Fcons (Fcons (lispy_name, make_number (256)), 12194 = Fcons (Fcons (Fcons (lispy_name, make_number (256)),
12195 Fcons (Fcons (lispy_full_name, 12195 Fcons (Fcons (lispy_full_name,
12196 make_number (fontp->size)), 12196 make_number (fontp->size)),
12197 Qnil)), 12197 Qnil)),
12198 XCONS (dpyinfo->name_list_element)->cdr); 12198 XCDR (dpyinfo->name_list_element));
12199 if (full_name) 12199 if (full_name)
12200 XCONS (dpyinfo->name_list_element)->cdr 12200 XCDR (dpyinfo->name_list_element)
12201 = Fcons (Fcons (Fcons (lispy_full_name, make_number (256)), 12201 = Fcons (Fcons (Fcons (lispy_full_name, make_number (256)),
12202 Fcons (Fcons (lispy_full_name, 12202 Fcons (Fcons (lispy_full_name,
12203 make_number (fontp->size)), 12203 make_number (fontp->size)),
12204 Qnil)), 12204 Qnil)),
12205 XCONS (dpyinfo->name_list_element)->cdr); 12205 XCDR (dpyinfo->name_list_element));
12206 } 12206 }
12207 12207
12208 /* The slot `encoding' specifies how to map a character 12208 /* The slot `encoding' specifies how to map a character
@@ -12288,12 +12288,12 @@ x_find_ccl_program (fontp)
12288{ 12288{
12289 Lisp_Object list, elt; 12289 Lisp_Object list, elt;
12290 12290
12291 for (list = Vfont_ccl_encoder_alist; CONSP (list); list = XCONS (list)->cdr) 12291 for (list = Vfont_ccl_encoder_alist; CONSP (list); list = XCDR (list))
12292 { 12292 {
12293 elt = XCONS (list)->car; 12293 elt = XCAR (list);
12294 if (CONSP (elt) 12294 if (CONSP (elt)
12295 && STRINGP (XCONS (elt)->car) 12295 && STRINGP (XCAR (elt))
12296 && (fast_c_string_match_ignore_case (XCONS (elt)->car, fontp->name) 12296 && (fast_c_string_match_ignore_case (XCAR (elt), fontp->name)
12297 >= 0)) 12297 >= 0))
12298 break; 12298 break;
12299 } 12299 }
@@ -12302,7 +12302,7 @@ x_find_ccl_program (fontp)
12302 struct ccl_program *ccl 12302 struct ccl_program *ccl
12303 = (struct ccl_program *) xmalloc (sizeof (struct ccl_program)); 12303 = (struct ccl_program *) xmalloc (sizeof (struct ccl_program));
12304 12304
12305 if (setup_ccl_program (ccl, XCONS (elt)->cdr) < 0) 12305 if (setup_ccl_program (ccl, XCDR (elt)) < 0)
12306 xfree (ccl); 12306 xfree (ccl);
12307 else 12307 else
12308 fontp->font_encoder = ccl; 12308 fontp->font_encoder = ccl;
@@ -12487,8 +12487,8 @@ x_term_init (display_name, xrm_option, resource_name)
12487 Lisp_Object tail; 12487 Lisp_Object tail;
12488 12488
12489 for (share = x_display_list, tail = x_display_name_list; share; 12489 for (share = x_display_list, tail = x_display_name_list; share;
12490 share = share->next, tail = XCONS (tail)->cdr) 12490 share = share->next, tail = XCDR (tail))
12491 if (same_x_server (XSTRING (XCONS (XCONS (tail)->car)->car)->data, 12491 if (same_x_server (XSTRING (XCAR (XCAR (tail)))->data,
12492 XSTRING (display_name)->data)) 12492 XSTRING (display_name)->data))
12493 break; 12493 break;
12494 if (share) 12494 if (share)
@@ -12524,7 +12524,7 @@ x_term_init (display_name, xrm_option, resource_name)
12524 /* Put it on x_display_name_list as well, to keep them parallel. */ 12524 /* Put it on x_display_name_list as well, to keep them parallel. */
12525 x_display_name_list = Fcons (Fcons (display_name, Qnil), 12525 x_display_name_list = Fcons (Fcons (display_name, Qnil),
12526 x_display_name_list); 12526 x_display_name_list);
12527 dpyinfo->name_list_element = XCONS (x_display_name_list)->car; 12527 dpyinfo->name_list_element = XCAR (x_display_name_list);
12528 12528
12529 dpyinfo->display = dpy; 12529 dpyinfo->display = dpy;
12530 12530
@@ -12743,22 +12743,22 @@ x_delete_display (dpyinfo)
12743 /* Discard this display from x_display_name_list and x_display_list. 12743 /* Discard this display from x_display_name_list and x_display_list.
12744 We can't use Fdelq because that can quit. */ 12744 We can't use Fdelq because that can quit. */
12745 if (! NILP (x_display_name_list) 12745 if (! NILP (x_display_name_list)
12746 && EQ (XCONS (x_display_name_list)->car, dpyinfo->name_list_element)) 12746 && EQ (XCAR (x_display_name_list), dpyinfo->name_list_element))
12747 x_display_name_list = XCONS (x_display_name_list)->cdr; 12747 x_display_name_list = XCDR (x_display_name_list);
12748 else 12748 else
12749 { 12749 {
12750 Lisp_Object tail; 12750 Lisp_Object tail;
12751 12751
12752 tail = x_display_name_list; 12752 tail = x_display_name_list;
12753 while (CONSP (tail) && CONSP (XCONS (tail)->cdr)) 12753 while (CONSP (tail) && CONSP (XCDR (tail)))
12754 { 12754 {
12755 if (EQ (XCONS (XCONS (tail)->cdr)->car, 12755 if (EQ (XCAR (XCDR (tail)),
12756 dpyinfo->name_list_element)) 12756 dpyinfo->name_list_element))
12757 { 12757 {
12758 XCONS (tail)->cdr = XCONS (XCONS (tail)->cdr)->cdr; 12758 XCDR (tail) = XCDR (XCDR (tail));
12759 break; 12759 break;
12760 } 12760 }
12761 tail = XCONS (tail)->cdr; 12761 tail = XCDR (tail);
12762 } 12762 }
12763 } 12763 }
12764 12764