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
ab7ce978
Commit
ab7ce978
authored
Oct 09, 2013
by
Paul Eggert
Browse files
* intervals.c (temp_set_point_both): Move test into 'eassert',
for speed.
parent
0d5d3029
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
2 deletions
+4
-2
src/ChangeLog
src/ChangeLog
+3
-0
src/intervals.c
src/intervals.c
+1
-2
No files found.
src/ChangeLog
View file @
ab7ce978
2013-10-09 Paul Eggert <eggert@cs.ucla.edu>
* intervals.c (temp_set_point_both): Move test into 'eassert',
for speed.
* lisp.h (eassert): Don't use 'assume'.
Sometimes 'assume' wins in performance, and sometimes it loses,
so it shouldn't be used all the time. Perhaps we need two
...
...
src/intervals.c
View file @
ab7ce978
...
...
@@ -1792,8 +1792,7 @@ temp_set_point_both (struct buffer *buffer,
ptrdiff_t
charpos
,
ptrdiff_t
bytepos
)
{
/* In a single-byte buffer, the two positions must be equal. */
if
(
BUF_ZV
(
buffer
)
==
BUF_ZV_BYTE
(
buffer
))
eassert
(
charpos
==
bytepos
);
eassert
(
BUF_ZV
(
buffer
)
!=
BUF_ZV_BYTE
(
buffer
)
||
charpos
==
bytepos
);
eassert
(
charpos
<=
bytepos
);
eassert
(
charpos
<=
BUF_ZV
(
buffer
)
||
BUF_BEGV
(
buffer
)
<=
charpos
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment