Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
03699b14
Commit
03699b14
authored
Sep 13, 1999
by
Ken Raeburn
Browse files
Use XCAR, XCDR, and XFLOAT_DATA instead of explicit member access.
parent
92610620
Changes
11
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
296 additions
and
296 deletions
+296
-296
src/category.c
src/category.c
+6
-6
src/ccl.c
src/ccl.c
+14
-14
src/coding.c
src/coding.c
+38
-38
src/doc.c
src/doc.c
+7
-7
src/editfns.c
src/editfns.c
+5
-5
src/eval.c
src/eval.c
+41
-41
src/fileio.c
src/fileio.c
+19
-19
src/filelock.c
src/filelock.c
+2
-2
src/insdel.c
src/insdel.c
+7
-7
src/intervals.c
src/intervals.c
+1
-1
src/keymap.c
src/keymap.c
+156
-156
No files found.
src/category.c
View file @
03699b14
...
@@ -591,15 +591,15 @@ word_boundary_p (c1, c2)
...
@@ -591,15 +591,15 @@ word_boundary_p (c1, c2)
if
(
NILP
(
category_set2
))
if
(
NILP
(
category_set2
))
return
default_result
;
return
default_result
;
for
(;
CONSP
(
tail
);
tail
=
XC
ONS
(
tail
)
->
cdr
)
for
(;
CONSP
(
tail
);
tail
=
XC
DR
(
tail
))
{
{
Lisp_Object
elt
=
XC
ONS
(
tail
)
->
car
;
Lisp_Object
elt
=
XC
AR
(
tail
);
if
(
CONSP
(
elt
)
if
(
CONSP
(
elt
)
&&
CATEGORYP
(
XC
ONS
(
elt
)
->
car
)
&&
CATEGORYP
(
XC
AR
(
elt
))
&&
CATEGORYP
(
XC
ONS
(
elt
)
->
cdr
)
&&
CATEGORYP
(
XC
DR
(
elt
))
&&
CATEGORY_MEMBER
(
XFASTINT
(
XC
ONS
(
elt
)
->
car
),
category_set1
)
&&
CATEGORY_MEMBER
(
XFASTINT
(
XC
AR
(
elt
)),
category_set1
)
&&
CATEGORY_MEMBER
(
XFASTINT
(
XC
ONS
(
elt
)
->
cdr
),
category_set2
))
&&
CATEGORY_MEMBER
(
XFASTINT
(
XC
DR
(
elt
)),
category_set2
))
return
!
default_result
;
return
!
default_result
;
}
}
return
default_result
;
return
default_result
;
...
...
src/ccl.c
View file @
03699b14
...
@@ -1328,7 +1328,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
...
@@ -1328,7 +1328,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
/* Check map varidity. */
/* Check map varidity. */
if
(
!
CONSP
(
map
))
continue
;
if
(
!
CONSP
(
map
))
continue
;
map
=
XC
ONS
(
map
)
->
cdr
;
map
=
XC
DR
(
map
);
if
(
!
VECTORP
(
map
))
continue
;
if
(
!
VECTORP
(
map
))
continue
;
size
=
XVECTOR
(
map
)
->
size
;
size
=
XVECTOR
(
map
)
->
size
;
if
(
size
<=
1
)
continue
;
if
(
size
<=
1
)
continue
;
...
@@ -1372,8 +1372,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
...
@@ -1372,8 +1372,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
}
}
else
if
(
CONSP
(
content
))
else
if
(
CONSP
(
content
))
{
{
attrib
=
XC
ONS
(
content
)
->
car
;
attrib
=
XC
AR
(
content
);
value
=
XC
ONS
(
content
)
->
cdr
;
value
=
XC
DR
(
content
);
if
(
!
NUMBERP
(
attrib
)
||
!
NUMBERP
(
value
))
if
(
!
NUMBERP
(
attrib
)
||
!
NUMBERP
(
value
))
continue
;
continue
;
reg
[
RRR
]
=
i
;
reg
[
RRR
]
=
i
;
...
@@ -1437,7 +1437,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
...
@@ -1437,7 +1437,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
/* Check map varidity. */
/* Check map varidity. */
if
(
!
CONSP
(
map
))
continue
;
if
(
!
CONSP
(
map
))
continue
;
map
=
XC
ONS
(
map
)
->
cdr
;
map
=
XC
DR
(
map
);
if
(
!
VECTORP
(
map
))
continue
;
if
(
!
VECTORP
(
map
))
continue
;
size
=
XVECTOR
(
map
)
->
size
;
size
=
XVECTOR
(
map
)
->
size
;
if
(
size
<=
1
)
continue
;
if
(
size
<=
1
)
continue
;
...
@@ -1477,8 +1477,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
...
@@ -1477,8 +1477,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
}
}
else
if
(
CONSP
(
content
))
else
if
(
CONSP
(
content
))
{
{
attrib
=
XC
ONS
(
content
)
->
car
;
attrib
=
XC
AR
(
content
);
value
=
XC
ONS
(
content
)
->
cdr
;
value
=
XC
DR
(
content
);
if
(
!
NUMBERP
(
attrib
)
||
!
NUMBERP
(
value
))
if
(
!
NUMBERP
(
attrib
)
||
!
NUMBERP
(
value
))
continue
;
continue
;
reg
[
RRR
]
=
i
;
reg
[
RRR
]
=
i
;
...
@@ -1522,7 +1522,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
...
@@ -1522,7 +1522,7 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
reg
[
RRR
]
=
-
1
;
reg
[
RRR
]
=
-
1
;
break
;
break
;
}
}
map
=
XC
ONS
(
map
)
->
cdr
;
map
=
XC
DR
(
map
);
if
(
!
VECTORP
(
map
))
if
(
!
VECTORP
(
map
))
{
{
reg
[
RRR
]
=
-
1
;
reg
[
RRR
]
=
-
1
;
...
@@ -1546,8 +1546,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
...
@@ -1546,8 +1546,8 @@ ccl_driver (ccl, source, destination, src_bytes, dst_bytes, consumed)
reg
[
RRR
]
=
i
;
reg
[
RRR
]
=
i
;
else
if
(
CONSP
(
content
))
else
if
(
CONSP
(
content
))
{
{
attrib
=
XC
ONS
(
content
)
->
car
;
attrib
=
XC
AR
(
content
);
value
=
XC
ONS
(
content
)
->
cdr
;
value
=
XC
DR
(
content
);
if
(
!
NUMBERP
(
attrib
)
||
!
NUMBERP
(
value
))
if
(
!
NUMBERP
(
attrib
)
||
!
NUMBERP
(
value
))
continue
;
continue
;
reg
[
rrr
]
=
XUINT
(
value
);
reg
[
rrr
]
=
XUINT
(
value
);
...
@@ -1663,8 +1663,8 @@ resolve_symbol_ccl_program (ccl)
...
@@ -1663,8 +1663,8 @@ resolve_symbol_ccl_program (ccl)
if
(
INTEGERP
(
contents
))
if
(
INTEGERP
(
contents
))
continue
;
continue
;
else
if
(
CONSP
(
contents
)
else
if
(
CONSP
(
contents
)
&&
SYMBOLP
(
XC
ONS
(
contents
)
->
car
)
&&
SYMBOLP
(
XC
AR
(
contents
))
&&
SYMBOLP
(
XC
ONS
(
contents
)
->
cdr
))
&&
SYMBOLP
(
XC
DR
(
contents
)))
{
{
/* This is the new style for embedding symbols. The form is
/* This is the new style for embedding symbols. The form is
(SYMBOL . PROPERTY). (get SYMBOL PROPERTY) should give
(SYMBOL . PROPERTY). (get SYMBOL PROPERTY) should give
...
@@ -1673,7 +1673,7 @@ resolve_symbol_ccl_program (ccl)
...
@@ -1673,7 +1673,7 @@ resolve_symbol_ccl_program (ccl)
if
(
EQ
(
result
,
ccl
))
if
(
EQ
(
result
,
ccl
))
result
=
Fcopy_sequence
(
ccl
);
result
=
Fcopy_sequence
(
ccl
);
val
=
Fget
(
XC
ONS
(
contents
)
->
car
,
XC
ONS
(
contents
)
->
cdr
);
val
=
Fget
(
XC
AR
(
contents
),
XC
DR
(
contents
));
if
(
NATNUMP
(
val
))
if
(
NATNUMP
(
val
))
XVECTOR
(
result
)
->
contents
[
i
]
=
val
;
XVECTOR
(
result
)
->
contents
[
i
]
=
val
;
else
else
...
@@ -2038,10 +2038,10 @@ Return index number of the registered map.")
...
@@ -2038,10 +2038,10 @@ Return index number of the registered map.")
if
(
!
CONSP
(
slot
))
if
(
!
CONSP
(
slot
))
break
;
break
;
if
(
EQ
(
symbol
,
XC
ONS
(
slot
)
->
car
))
if
(
EQ
(
symbol
,
XC
AR
(
slot
)))
{
{
index
=
make_number
(
i
);
index
=
make_number
(
i
);
XC
ONS
(
slot
)
->
cdr
=
map
;
XC
DR
(
slot
)
=
map
;
Fput
(
symbol
,
Qcode_conversion_map
,
map
);
Fput
(
symbol
,
Qcode_conversion_map
,
map
);
Fput
(
symbol
,
Qcode_conversion_map_id
,
index
);
Fput
(
symbol
,
Qcode_conversion_map_id
,
index
);
return
index
;
return
index
;
...
...
src/coding.c
View file @
03699b14
...
@@ -2974,9 +2974,9 @@ setup_coding_system (coding_system, coding)
...
@@ -2974,9 +2974,9 @@ setup_coding_system (coding_system, coding)
bzero
(
coding
->
safe_charsets
,
MAX_CHARSET
+
1
);
bzero
(
coding
->
safe_charsets
,
MAX_CHARSET
+
1
);
while
(
CONSP
(
val
))
while
(
CONSP
(
val
))
{
{
if ((i = get_charset_id (XC
ONS
(val)
->car
)) >= 0)
if
((
i
=
get_charset_id
(
XC
AR
(
val
)))
>=
0
)
coding
->
safe_charsets
[
i
]
=
1
;
coding
->
safe_charsets
[
i
]
=
1
;
val = XC
ONS
(val)
->cdr
;
val
=
XC
DR
(
val
);
}
}
}
}
...
@@ -3042,12 +3042,12 @@ setup_coding_system (coding_system, coding)
...
@@ -3042,12 +3042,12 @@ setup_coding_system (coding_system, coding)
val
=
Vcharset_revision_alist
;
val
=
Vcharset_revision_alist
;
while
(
CONSP
(
val
))
while
(
CONSP
(
val
))
{
{
charset = get_charset_id (Fcar_safe (XC
ONS
(val)
->car
));
charset
=
get_charset_id
(
Fcar_safe
(
XC
AR
(
val
)));
if
(
charset
>=
0
if
(
charset
>=
0
&& (temp = Fcdr_safe (XC
ONS
(val)
->car
), INTEGERP (temp))
&&
(
temp
=
Fcdr_safe
(
XC
AR
(
val
)),
INTEGERP
(
temp
))
&&
(
i
=
XINT
(
temp
),
(
i
>=
0
&&
(
i
+
'@'
)
<
128
)))
&&
(
i
=
XINT
(
temp
),
(
i
>=
0
&&
(
i
+
'@'
)
<
128
)))
CODING_SPEC_ISO_REVISION_NUMBER
(
coding
,
charset
)
=
i
;
CODING_SPEC_ISO_REVISION_NUMBER
(
coding
,
charset
)
=
i
;
val = XC
ONS
(val)
->cdr
;
val
=
XC
DR
(
val
);
}
}
/* Checks FLAGS[REG] (REG = 0, 1, 2 3) and decide designations.
/* Checks FLAGS[REG] (REG = 0, 1, 2 3) and decide designations.
...
@@ -3084,28 +3084,28 @@ setup_coding_system (coding_system, coding)
...
@@ -3084,28 +3084,28 @@ setup_coding_system (coding_system, coding)
tail
=
flags
[
i
];
tail
=
flags
[
i
];
coding
->
flags
|=
CODING_FLAG_ISO_DESIGNATION
;
coding
->
flags
|=
CODING_FLAG_ISO_DESIGNATION
;
if (INTEGERP (XC
ONS
(tail)
->car
)
if
(
INTEGERP
(
XC
AR
(
tail
))
&& (charset = XINT (XC
ONS
(tail)
->car
),
&&
(
charset
=
XINT
(
XC
AR
(
tail
)),
CHARSET_VALID_P
(
charset
))
CHARSET_VALID_P
(
charset
))
|| (charset = get_charset_id (XC
ONS
(tail)
->car
)) >= 0)
||
(
charset
=
get_charset_id
(
XC
AR
(
tail
)))
>=
0
)
{
{
CODING_SPEC_ISO_INITIAL_DESIGNATION
(
coding
,
i
)
=
charset
;
CODING_SPEC_ISO_INITIAL_DESIGNATION
(
coding
,
i
)
=
charset
;
CODING_SPEC_ISO_REQUESTED_DESIGNATION
(
coding
,
charset
)
=
i
;
CODING_SPEC_ISO_REQUESTED_DESIGNATION
(
coding
,
charset
)
=
i
;
}
}
else
else
CODING_SPEC_ISO_INITIAL_DESIGNATION
(
coding
,
i
)
=
-
1
;
CODING_SPEC_ISO_INITIAL_DESIGNATION
(
coding
,
i
)
=
-
1
;
tail = XC
ONS
(tail)
->cdr
;
tail
=
XC
DR
(
tail
);
while
(
CONSP
(
tail
))
while
(
CONSP
(
tail
))
{
{
if (INTEGERP (XC
ONS
(tail)
->car
)
if
(
INTEGERP
(
XC
AR
(
tail
))
&& (charset = XINT (XC
ONS
(tail)
->car
),
&&
(
charset
=
XINT
(
XC
AR
(
tail
)),
CHARSET_VALID_P
(
charset
))
CHARSET_VALID_P
(
charset
))
|| (charset = get_charset_id (XC
ONS
(tail)
->car
)) >= 0)
||
(
charset
=
get_charset_id
(
XC
AR
(
tail
)))
>=
0
)
CODING_SPEC_ISO_REQUESTED_DESIGNATION
(
coding
,
charset
)
CODING_SPEC_ISO_REQUESTED_DESIGNATION
(
coding
,
charset
)
=
i
;
=
i
;
else if (EQ (XC
ONS
(tail)
->car
, Qt))
else
if
(
EQ
(
XC
AR
(
tail
),
Qt
))
reg_bits
|=
1
<<
i
;
reg_bits
|=
1
<<
i
;
tail = XC
ONS
(tail)
->cdr
;
tail
=
XC
DR
(
tail
);
}
}
}
}
else
else
...
@@ -3168,9 +3168,9 @@ setup_coding_system (coding_system, coding)
...
@@ -3168,9 +3168,9 @@ setup_coding_system (coding_system, coding)
val
=
XVECTOR
(
coding_spec
)
->
contents
[
4
];
val
=
XVECTOR
(
coding_spec
)
->
contents
[
4
];
if
(
!
CONSP
(
val
)
if
(
!
CONSP
(
val
)
||
setup_ccl_program
(
&
(
coding
->
spec
.
ccl
.
decoder
),
||
setup_ccl_program
(
&
(
coding
->
spec
.
ccl
.
decoder
),
XC
ONS
(val)
->car
) < 0
XC
AR
(
val
))
<
0
||
setup_ccl_program
(
&
(
coding
->
spec
.
ccl
.
encoder
),
||
setup_ccl_program
(
&
(
coding
->
spec
.
ccl
.
encoder
),
XC
ONS
(val)
->cdr
) < 0)
XC
DR
(
val
))
<
0
)
goto
label_invalid_coding_system
;
goto
label_invalid_coding_system
;
bzero
(
coding
->
spec
.
ccl
.
valid_codes
,
256
);
bzero
(
coding
->
spec
.
ccl
.
valid_codes
,
256
);
...
@@ -3179,18 +3179,18 @@ setup_coding_system (coding_system, coding)
...
@@ -3179,18 +3179,18 @@ setup_coding_system (coding_system, coding)
{
{
Lisp_Object
this
;
Lisp_Object
this
;
for (; CONSP (val); val = XC
ONS
(val)
->cdr
)
for
(;
CONSP
(
val
);
val
=
XC
DR
(
val
))
{
{
this = XC
ONS
(val)
->car
;
this
=
XC
AR
(
val
);
if
(
INTEGERP
(
this
)
if
(
INTEGERP
(
this
)
&&
XINT
(
this
)
>=
0
&&
XINT
(
this
)
<
256
)
&&
XINT
(
this
)
>=
0
&&
XINT
(
this
)
<
256
)
coding
->
spec
.
ccl
.
valid_codes
[
XINT
(
this
)]
=
1
;
coding
->
spec
.
ccl
.
valid_codes
[
XINT
(
this
)]
=
1
;
else
if
(
CONSP
(
this
)
else
if
(
CONSP
(
this
)
&& INTEGERP (XC
ONS
(this)
->car
)
&&
INTEGERP
(
XC
AR
(
this
))
&& INTEGERP (XC
ONS
(this)
->cdr
))
&&
INTEGERP
(
XC
DR
(
this
)))
{
{
int start = XINT (XC
ONS
(this)
->car
);
int
start
=
XINT
(
XC
AR
(
this
));
int end = XINT (XC
ONS
(this)
->cdr
);
int
end
=
XINT
(
XC
DR
(
this
));
if
(
start
>=
0
&&
start
<=
end
&&
end
<
256
)
if
(
start
>=
0
&&
start
<=
end
&&
end
<
256
)
while
(
start
<=
end
)
while
(
start
<=
end
)
...
@@ -4876,13 +4876,13 @@ detect_coding_system (src, src_bytes, highest)
...
@@ -4876,13 +4876,13 @@ detect_coding_system (src, src_bytes, highest)
/* At first, gather possible coding systems in VAL. */
/* At first, gather possible coding systems in VAL. */
val
=
Qnil
;
val
=
Qnil
;
for (tmp = Vcoding_category_list; !NILP (tmp); tmp = XC
ONS
(tmp)
->cdr
)
for
(
tmp
=
Vcoding_category_list
;
!
NILP
(
tmp
);
tmp
=
XC
DR
(
tmp
))
{
{
int
idx
int
idx
= XFASTINT (Fget (XC
ONS
(tmp)
->car
, Qcoding_category_index));
=
XFASTINT
(
Fget
(
XC
AR
(
tmp
),
Qcoding_category_index
));
if
(
coding_mask
&
(
1
<<
idx
))
if
(
coding_mask
&
(
1
<<
idx
))
{
{
val = Fcons (Fsymbol_value (XC
ONS
(tmp)
->car
), val);
val
=
Fcons
(
Fsymbol_value
(
XC
AR
(
tmp
)),
val
);
if
(
highest
)
if
(
highest
)
break
;
break
;
}
}
...
@@ -4891,18 +4891,18 @@ detect_coding_system (src, src_bytes, highest)
...
@@ -4891,18 +4891,18 @@ detect_coding_system (src, src_bytes, highest)
val
=
Fnreverse
(
val
);
val
=
Fnreverse
(
val
);
/* Then, replace the elements with subsidiary coding systems. */
/* Then, replace the elements with subsidiary coding systems. */
for (tmp = val; !NILP (tmp); tmp = XC
ONS
(tmp)
->cdr
)
for
(
tmp
=
val
;
!
NILP
(
tmp
);
tmp
=
XC
DR
(
tmp
))
{
{
if
(
eol_type
!=
CODING_EOL_UNDECIDED
if
(
eol_type
!=
CODING_EOL_UNDECIDED
&&
eol_type
!=
CODING_EOL_INCONSISTENT
)
&&
eol_type
!=
CODING_EOL_INCONSISTENT
)
{
{
Lisp_Object
eol
;
Lisp_Object
eol
;
eol = Fget (XC
ONS
(tmp)
->car
, Qeol_type);
eol
=
Fget
(
XC
AR
(
tmp
),
Qeol_type
);
if
(
VECTORP
(
eol
))
if
(
VECTORP
(
eol
))
XC
ONS
(tmp)
->car
= XVECTOR (eol)->contents[eol_type];
XC
AR
(
tmp
)
=
XVECTOR
(
eol
)
->
contents
[
eol_type
];
}
}
}
}
return (highest ? XC
ONS
(val)
->car
: val);
return
(
highest
?
XC
AR
(
val
)
:
val
);
}
}
DEFUN
(
"detect-coding-region"
,
Fdetect_coding_region
,
Sdetect_coding_region
,
DEFUN
(
"detect-coding-region"
,
Fdetect_coding_region
,
Sdetect_coding_region
,
...
@@ -5324,18 +5324,18 @@ which is a list of all the arguments given to this function.")
...
@@ -5324,18 +5324,18 @@ which is a list of all the arguments given to this function.")
if
(
NILP
(
chain
))
if
(
NILP
(
chain
))
return
Qnil
;
return
Qnil
;
for (; CONSP (chain); chain = XC
ONS
(chain)
->cdr
)
for
(;
CONSP
(
chain
);
chain
=
XC
DR
(
chain
))
{
{
Lisp_Object
elt
;
Lisp_Object
elt
;
elt = XC
ONS
(chain)
->car
;
elt
=
XC
AR
(
chain
);
if
(
CONSP
(
elt
)
if
(
CONSP
(
elt
)
&&
((
STRINGP
(
target
)
&&
((
STRINGP
(
target
)
&& STRINGP (XC
ONS
(elt)
->car
)
&&
STRINGP
(
XC
AR
(
elt
))
&& fast_string_match (XC
ONS
(elt)
->car
, target) >= 0)
&&
fast_string_match
(
XC
AR
(
elt
),
target
)
>=
0
)
|| (INTEGERP (target) && EQ (target, XC
ONS
(elt)
->car
))))
||
(
INTEGERP
(
target
)
&&
EQ
(
target
,
XC
AR
(
elt
)))))
{
{
val = XC
ONS
(elt)
->cdr
;
val
=
XC
DR
(
elt
);
/* Here, if VAL is both a valid coding system and a valid
/* Here, if VAL is both a valid coding system and a valid
function symbol, we return VAL as a coding system. */
function symbol, we return VAL as a coding system. */
if
(
CONSP
(
val
))
if
(
CONSP
(
val
))
...
@@ -5406,13 +5406,13 @@ This function is internal use only.")
...
@@ -5406,13 +5406,13 @@ This function is internal use only.")
while
(
CONSP
(
val
)
&&
i
<
CODING_CATEGORY_IDX_MAX
)
while
(
CONSP
(
val
)
&&
i
<
CODING_CATEGORY_IDX_MAX
)
{
{
if (! SYMBOLP (XC
ONS
(val)
->car
))
if
(
!
SYMBOLP
(
XC
AR
(
val
)))
break
;
break
;
idx = XFASTINT (Fget (XC
ONS
(val)
->car
, Qcoding_category_index));
idx
=
XFASTINT
(
Fget
(
XC
AR
(
val
),
Qcoding_category_index
));
if
(
idx
>=
CODING_CATEGORY_IDX_MAX
)
if
(
idx
>=
CODING_CATEGORY_IDX_MAX
)
break
;
break
;
coding_priorities
[
i
++
]
=
(
1
<<
idx
);
coding_priorities
[
i
++
]
=
(
1
<<
idx
);
val = XC
ONS
(val)
->cdr
;
val
=
XC
DR
(
val
);
}
}
/* If coding-category-list is valid and contains all coding
/* If coding-category-list is valid and contains all coding
categories, `i' should be CODING_CATEGORY_IDX_MAX now. If not,
categories, `i' should be CODING_CATEGORY_IDX_MAX now. If not,
...
...
src/doc.c
View file @
03699b14
...
@@ -126,8 +126,8 @@ get_doc_string (filepos, unibyte, definition)
...
@@ -126,8 +126,8 @@ get_doc_string (filepos, unibyte, definition)
}
}
else
if
(
CONSP
(
filepos
))
else
if
(
CONSP
(
filepos
))
{
{
file
=
XC
ONS
(
filepos
)
->
car
;
file
=
XC
AR
(
filepos
);
position
=
XINT
(
XC
ONS
(
filepos
)
->
cdr
);
position
=
XINT
(
XC
DR
(
filepos
));
if
(
position
<
0
)
if
(
position
<
0
)
position
=
-
position
;
position
=
-
position
;
}
}
...
@@ -353,7 +353,7 @@ string is passed through `substitute-command-keys'.")
...
@@ -353,7 +353,7 @@ string is passed through `substitute-command-keys'.")
/* Handle a doc reference--but these never come last
/* Handle a doc reference--but these never come last
in the function body, so reject them if they are last. */
in the function body, so reject them if they are last. */
else
if
((
NATNUMP
(
tem
)
||
CONSP
(
tem
))
else
if
((
NATNUMP
(
tem
)
||
CONSP
(
tem
))
&&
!
NILP
(
XC
ONS
(
tem1
)
->
cdr
))
&&
!
NILP
(
XC
DR
(
tem1
)))
doc
=
get_doc_string
(
tem
,
0
,
0
);
doc
=
get_doc_string
(
tem
,
0
,
0
);
else
else
return
Qnil
;
return
Qnil
;
...
@@ -424,15 +424,15 @@ store_function_docstring (fun, offset)
...
@@ -424,15 +424,15 @@ store_function_docstring (fun, offset)
{
{
Lisp_Object
tem
;
Lisp_Object
tem
;
tem
=
XC
ONS
(
fun
)
->
car
;
tem
=
XC
AR
(
fun
);
if
(
EQ
(
tem
,
Qlambda
)
||
EQ
(
tem
,
Qautoload
))
if
(
EQ
(
tem
,
Qlambda
)
||
EQ
(
tem
,
Qautoload
))
{
{
tem
=
Fcdr
(
Fcdr
(
fun
));
tem
=
Fcdr
(
Fcdr
(
fun
));
if
(
CONSP
(
tem
)
&&
INTEGERP
(
XC
ONS
(
tem
)
->
car
))
if
(
CONSP
(
tem
)
&&
INTEGERP
(
XC
AR
(
tem
)))
XSETFASTINT
(
XC
ONS
(
tem
)
->
car
,
offset
);
XSETFASTINT
(
XC
AR
(
tem
),
offset
);
}
}
else
if
(
EQ
(
tem
,
Qmacro
))
else
if
(
EQ
(
tem
,
Qmacro
))
store_function_docstring
(
XC
ONS
(
fun
)
->
cdr
,
offset
);
store_function_docstring
(
XC
DR
(
fun
),
offset
);
}
}
/* Bytecode objects sometimes have slots for it. */
/* Bytecode objects sometimes have slots for it. */
...
...
src/editfns.c
View file @
03699b14
...
@@ -2288,13 +2288,13 @@ save_restriction_restore (data)
...
@@ -2288,13 +2288,13 @@ save_restriction_restore (data)
register
Lisp_Object
tem
;
register
Lisp_Object
tem
;
int
obegv
,
ozv
;
int
obegv
,
ozv
;
buf
=
XBUFFER
(
XC
ONS
(
data
)
->
car
);
buf
=
XBUFFER
(
XC
AR
(
data
));
data
=
XC
ONS
(
data
)
->
cdr
;
data
=
XC
DR
(
data
);
tem
=
XC
ONS
(
data
)
->
car
;
tem
=
XC
AR
(
data
);
newhead
=
XINT
(
tem
);
newhead
=
XINT
(
tem
);
tem
=
XC
ONS
(
data
)
->
cdr
;
tem
=
XC
DR
(
data
);
newtail
=
XINT
(
tem
);
newtail
=
XINT
(
tem
);
if
(
newhead
+
newtail
>
BUF_Z
(
buf
)
-
BUF_BEG
(
buf
))
if
(
newhead
+
newtail
>
BUF_Z
(
buf
)
-
BUF_BEG
(
buf
))
{
{
...
@@ -2761,7 +2761,7 @@ Use %% to put a single % into the output.")
...
@@ -2761,7 +2761,7 @@ Use %% to put a single % into the output.")
if
(
INTEGERP
(
args
[
n
]))
if
(
INTEGERP
(
args
[
n
]))
sprintf
(
p
,
this_format
,
XINT
(
args
[
n
]));
sprintf
(
p
,
this_format
,
XINT
(
args
[
n
]));
else
else
sprintf
(
p
,
this_format
,
XFLOAT
(
args
[
n
])
->
data
);
sprintf
(
p
,
this_format
,
XFLOAT
_DATA
(
args
[
n
]));
if
(
p
>
buf
if
(
p
>
buf
&&
multibyte
&&
multibyte
...
...
src/eval.c
View file @
03699b14
...
@@ -322,11 +322,11 @@ CONDITION's value if non-nil is returned from the cond-form.")
...
@@ -322,11 +322,11 @@ CONDITION's value if non-nil is returned from the cond-form.")
val
=
Feval
(
Fcar
(
clause
));
val
=
Feval
(
Fcar
(
clause
));
if
(
!
NILP
(
val
))
if
(
!
NILP
(
val
))
{
{
if
(
!
EQ
(
XC
ONS
(
clause
)
->
cdr
,
Qnil
))
if
(
!
EQ
(
XC
DR
(
clause
),
Qnil
))
val
=
Fprogn
(
XC
ONS
(
clause
)
->
cdr
);
val
=
Fprogn
(
XC
DR
(
clause
));
break
;
break
;
}
}
args
=
XC
ONS
(
args
)
->
cdr
;
args
=
XC
DR
(
args
);
}
}
UNGCPRO
;
UNGCPRO
;
...
@@ -670,9 +670,9 @@ for the variable is `*'.")
...
@@ -670,9 +670,9 @@ for the variable is `*'.")
return
Qt
;
return
Qt
;
/* If it is (STRING . INTEGER), a negative integer means a user variable. */
/* If it is (STRING . INTEGER), a negative integer means a user variable. */
if
(
CONSP
(
documentation
)
if
(
CONSP
(
documentation
)
&&
STRINGP
(
XC
ONS
(
documentation
)
->
car
)
&&
STRINGP
(
XC
AR
(
documentation
))
&&
INTEGERP
(
XC
ONS
(
documentation
)
->
cdr
)
&&
INTEGERP
(
XC
DR
(
documentation
))
&&
XINT
(
XC
ONS
(
documentation
)
->
cdr
)
<
0
)
&&
XINT
(
XC
DR
(
documentation
))
<
0
)
return
Qt
;
return
Qt
;
return
Qnil
;
return
Qnil
;
}
}
...
@@ -818,7 +818,7 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
...
@@ -818,7 +818,7 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
if
(
!
CONSP
(
form
))
if
(
!
CONSP
(
form
))
break
;
break
;
/* Set SYM, give DEF and TEM right values in case SYM is not a symbol. */
/* Set SYM, give DEF and TEM right values in case SYM is not a symbol. */
def
=
sym
=
XC
ONS
(
form
)
->
car
;
def
=
sym
=
XC
AR
(
form
);
tem
=
Qnil
;
tem
=
Qnil
;
/* Trace symbols aliases to other symbols
/* Trace symbols aliases to other symbols
until we get a symbol that is not an alias. */
until we get a symbol that is not an alias. */
...
@@ -844,7 +844,7 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
...
@@ -844,7 +844,7 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
if
(
EQ
(
def
,
Qunbound
)
||
!
CONSP
(
def
))
if
(
EQ
(
def
,
Qunbound
)
||
!
CONSP
(
def
))
/* Not defined or definition not suitable */
/* Not defined or definition not suitable */
break
;
break
;
if
(
EQ
(
XC
ONS
(
def
)
->
car
,
Qautoload
))
if
(
EQ
(
XC
AR
(
def
),
Qautoload
))
{
{
/* Autoloading function: will it be a macro when loaded? */
/* Autoloading function: will it be a macro when loaded? */
tem
=
Fnth
(
make_number
(
4
),
def
);
tem
=
Fnth
(
make_number
(
4
),
def
);
...
@@ -860,17 +860,17 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
...
@@ -860,17 +860,17 @@ definitions to shadow the loaded ones for use in file byte-compilation.")
else
else
break
;
break
;
}
}
else
if
(
!
EQ
(
XC
ONS
(
def
)
->
car
,
Qmacro
))
else
if
(
!
EQ
(
XC
AR
(
def
),
Qmacro
))
break
;
break
;
else
expander
=
XC
ONS
(
def
)
->
cdr
;
else
expander
=
XC
DR
(
def
);
}
}
else
else
{
{
expander
=
XC
ONS
(
tem
)
->
cdr
;
expander
=
XC
DR
(
tem
);
if
(
NILP
(
expander
))
if
(
NILP
(
expander
))
break
;
break
;
}
}
form
=
apply1
(
expander
,
XC
ONS
(
form
)
->
cdr
);
form
=
apply1
(
expander
,
XC
DR
(
form
));
}
}
return
form
;
return
form
;
}
}
...
@@ -1062,8 +1062,8 @@ See also the function `signal' for more info.")
...
@@ -1062,8 +1062,8 @@ See also the function `signal' for more info.")
tem
=
Fcar
(
val
);
tem
=
Fcar
(
val
);
if
(
!
(
NILP
(
tem
)
if
(
!
(
NILP
(
tem
)
||
(
CONSP
(
tem
)
||
(
CONSP
(
tem
)
&&
(
SYMBOLP
(
XC
ONS
(
tem
)
->
car
)
&&
(
SYMBOLP
(
XC
AR
(
tem
))