annotate src/lisp-union.h @ 388:aabb7f5b1c81 r21-2-9

Import from CVS: tag r21-2-9
author cvs
date Mon, 13 Aug 2007 11:09:42 +0200
parents 8626e4521993
children 74fd4e045ea6
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1 /* Fundamental definitions for XEmacs Lisp interpreter -- union objects.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
2 Copyright (C) 1985, 1986, 1987, 1992, 1993, 1994
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
3 Free Software Foundation, Inc.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
4
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
5 This file is part of XEmacs.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
6
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
7 XEmacs is free software; you can redistribute it and/or modify it
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
8 under the terms of the GNU General Public License as published by the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
9 Free Software Foundation; either version 2, or (at your option) any
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
10 later version.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
11
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
12 XEmacs is distributed in the hope that it will be useful, but WITHOUT
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
15 for more details.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
16
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
17 You should have received a copy of the GNU General Public License
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
18 along with XEmacs; see the file COPYING. If not, write to
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
20 Boston, MA 02111-1307, USA. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
21
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
22 /* Divergent from FSF. */
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
23
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
24 /* Definition of Lisp_Object type as a union.
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
25 The declaration order of the objects within the struct members
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
26 of the union is dependent on ENDIAN-ness and USE_MINIMAL_TAGBITS.
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
27 See lisp-disunion.h for more details. */
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
28
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
29 typedef
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
30 union Lisp_Object
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
31 {
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
32 /* if non-valbits are at lower addresses */
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
33 #if defined(WORDS_BIGENDIAN) == defined(USE_MINIMAL_TAGBITS)
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
34 struct
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
35 {
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
36 EMACS_UINT val : VALBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
37 #if GCMARKBITS > 0
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
38 unsigned int markbit: GCMARKBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
39 #endif
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
40 enum_field (Lisp_Type) type : GCTYPEBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
41 } gu;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
42
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
43 struct
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
44 {
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
45 signed EMACS_INT val : INT_VALBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
46 unsigned int bits : INT_GCBITS;
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
47 } s;
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
48
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
49 struct
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
50 {
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
51 EMACS_UINT val : INT_VALBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
52 unsigned int bits : INT_GCBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
53 } u;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
54 #else /* non-valbits are at higher addresses */
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
55 struct
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
56 {
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
57 enum_field (Lisp_Type) type : GCTYPEBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
58 #if GCMARKBITS > 0
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
59 unsigned int markbit: GCMARKBITS;
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
60 #endif
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
61 EMACS_UINT val : VALBITS;
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
62 } gu;
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
63
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
64 struct
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
65 {
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
66 unsigned int bits : INT_GCBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
67 signed EMACS_INT val : INT_VALBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
68 } s;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
69
207
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
70 struct
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
71 {
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
72 unsigned int bits : INT_GCBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
73 EMACS_UINT val : INT_VALBITS;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
74 } u;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
75
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
76 #endif /* non-valbits are at higher addresses */
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
77
207
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
78 EMACS_UINT ui;
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
79 signed EMACS_INT i;
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
80
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
81 /* This was formerly declared 'void *v' etc. but that causes
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
82 GCC to accept any (yes, any) pointer as the argument of
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
83 a function declared to accept a Lisp_Object. */
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
84 struct nosuchstruct *v;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
85 CONST struct nosuchstruct *cv;
185
3d6bfa290dbd Import from CVS: tag r20-3b19
cvs
parents: 0
diff changeset
86 }
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
87 Lisp_Object;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
88
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
89 #define XCHARVAL(x) ((x).gu.val)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
90
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
91 #ifdef USE_MINIMAL_TAGBITS
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
92
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
93 # define XSETINT(var, value) do { \
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
94 EMACS_INT xset_value = (value); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
95 Lisp_Object *xset_var = &(var); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
96 xset_var->s.bits = 1; \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
97 xset_var->s.val = xset_value; \
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
98 } while (0)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
99 # define XSETCHAR(var, value) do { \
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
100 Emchar xset_value = (value); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
101 Lisp_Object *xset_var = &(var); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
102 xset_var->gu.type = Lisp_Type_Char; \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
103 xset_var->gu.val = xset_value; \
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
104 } while (0)
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
105 # define XSETOBJ(var, vartype, value) do { \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
106 EMACS_UINT xset_value = (EMACS_UINT) (value); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
107 (var).ui = xset_value; \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
108 } while (0)
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
109 # define XPNTRVAL(x) ((x).ui)
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
110
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
111 #else /* ! USE_MINIMAL_TAGBITS */
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
112
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
113 # define XSETOBJ(var, vartype, value) do { \
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
114 EMACS_UINT xset_value = (EMACS_UINT) (value); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
115 Lisp_Object *xset_var = &(var); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
116 xset_var->gu.type = (vartype); \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
117 xset_var->gu.markbit = 0; \
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
118 xset_var->gu.val = xset_value; \
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
119 } while (0)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
120 # define XSETINT(var, value) XSETOBJ (var, Lisp_Type_Int, value)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
121 # define XSETCHAR(var, value) XSETOBJ (var, Lisp_Type_Char, value)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
122 # define XPNTRVAL(x) ((x).gu.val)
380
8626e4521993 Import from CVS: tag r21-2-5
cvs
parents: 272
diff changeset
123
207
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
124 #endif /* ! USE_MINIMAL_TAGBITS */
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
125
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
126 INLINE Lisp_Object make_int (EMACS_INT val);
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
127 INLINE Lisp_Object
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
128 make_int (EMACS_INT val)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
129 {
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
130 Lisp_Object obj;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
131 XSETINT(obj, val);
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
132 return obj;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
133 }
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
134
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
135 INLINE Lisp_Object make_char (Emchar val);
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
136 INLINE Lisp_Object
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
137 make_char (Emchar val)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
138 {
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
139 Lisp_Object obj;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
140 XSETCHAR(obj, val);
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
141 return obj;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
142 }
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
143
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
144 extern Lisp_Object Qnull_pointer, Qzero;
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
145
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
146 #define XREALINT(x) ((x).s.val)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
147 #define XUINT(x) ((x).u.val)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
148 #define XTYPE(x) ((x).gu.type)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
149 #define XGCTYPE(x) XTYPE (x)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
150 #define EQ(x,y) ((x).v == (y).v)
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
151
207
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
152 #ifdef USE_MINIMAL_TAGBITS
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
153 #define INTP(x) ((x).s.bits)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
154 #define GC_EQ(x,y) EQ (x, y)
259
11cf20601dec Import from CVS: tag r20-5b28
cvs
parents: 213
diff changeset
155 #else
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
156 #define INTP(x) (XTYPE(x) == Lisp_Type_Int)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
157 #define GC_EQ(x,y) ((x).gu.val == (y).gu.val && XTYPE (x) == XTYPE (y))
207
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
158 #endif
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
159
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
160 #if GCMARKBITS > 0
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
161 /* XMARKBIT accesses the markbit. Markbits are used only in
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
162 particular slots of particular structure types. Other markbits are
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
163 always zero. Outside of garbage collection, all mark bits are
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
164 always zero. */
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
165 # define XMARKBIT(x) ((x).gu.markbit)
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
166 # define XMARK(x) ((void) (XMARKBIT (x) = 1))
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
167 # define XUNMARK(x) ((void) (XMARKBIT (x) = 0))
207
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
168 #else
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
169 # define XUNMARK(x) DO_NOTHING
207
e45d5e7c476e Import from CVS: tag r20-4b2
cvs
parents: 185
diff changeset
170 #endif
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
171
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
172 /* Convert between a (void *) and a Lisp_Object, as when the
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
173 Lisp_Object is passed to a toolkit callback function */
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
174 #define VOID_TO_LISP(larg,varg) \
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
175 ((void) ((larg).v = (struct nosuchstruct *) (varg)))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
176 #define CVOID_TO_LISP(larg,varg) \
272
c5d627a313b1 Import from CVS: tag r21-0b34
cvs
parents: 259
diff changeset
177 ((void) ((larg).cv = (CONST struct nosuchstruct *) (varg)))
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
178 #define LISP_TO_VOID(larg) ((void *) ((larg).v))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
179 #define LISP_TO_CVOID(larg) ((CONST void *) ((larg).cv))
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
180
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
181 /* Convert a Lisp_Object into something that can't be used as an
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
182 lvalue. Useful for type-checking. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
183 #if (__GNUC__ > 1)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
184 #define NON_LVALUE(larg) ({ (larg); })
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
185 #else
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
186 /* Well, you can't really do it without using a function call, and
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
187 there's no real point in that; no-union-type is the rule, and that
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
188 will catch errors. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
189 #define NON_LVALUE(larg) (larg)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
190 #endif