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
7c85f529
Commit
7c85f529
authored
Sep 21, 2011
by
Paul Eggert
Browse files
Fix ptrdiff_t/EMACS_INT confusion.
parent
2972b14b
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
19 additions
and
19 deletions
+19
-19
src/bidi.c
src/bidi.c
+1
-1
src/fns.c
src/fns.c
+1
-1
src/indent.h
src/indent.h
+6
-6
src/intervals.c
src/intervals.c
+1
-1
src/keyboard.c
src/keyboard.c
+1
-1
src/print.c
src/print.c
+4
-4
src/syntax.c
src/syntax.c
+2
-2
src/xdisp.c
src/xdisp.c
+3
-3
No files found.
src/bidi.c
View file @
7c85f529
...
...
@@ -2411,6 +2411,6 @@ bidi_dump_cached_states (void)
fputs
(
"
\n
"
,
stderr
);
fputs
(
"pos "
,
stderr
);
for
(
i
=
0
;
i
<
bidi_cache_idx
;
i
++
)
fprintf
(
stderr
,
"%*"
p
I
"d"
,
ndigits
,
bidi_cache
[
i
].
charpos
);
fprintf
(
stderr
,
"%*"
p
D
"d"
,
ndigits
,
bidi_cache
[
i
].
charpos
);
fputs
(
"
\n
"
,
stderr
);
}
src/fns.c
View file @
7c85f529
...
...
@@ -1108,7 +1108,7 @@ an error is signaled. */)
ptrdiff_t
converted
=
str_to_unibyte
(
SDATA
(
string
),
str
,
chars
,
0
);
if
(
converted
<
chars
)
error
(
"Can't convert the %"
p
I
"dth character to unibyte"
,
converted
);
error
(
"Can't convert the %"
p
D
"dth character to unibyte"
,
converted
);
string
=
make_unibyte_string
((
char
*
)
str
,
chars
);
xfree
(
str
);
}
...
...
src/indent.h
View file @
7c85f529
...
...
@@ -26,13 +26,13 @@ struct position
int
contin
;
};
struct
position
*
compute_motion
(
ptrdiff_t
from
,
ptrdiff_t
fromvpos
,
ptrdiff_t
fromhpos
,
int
did_motion
,
ptrdiff_t
to
,
ptrdiff_t
tovpos
,
ptrdiff_t
tohpos
,
ptrdiff_t
width
,
ptrdiff_t
hscroll
,
struct
position
*
compute_motion
(
ptrdiff_t
from
,
EMACS_INT
fromvpos
,
EMACS_INT
fromhpos
,
int
did_motion
,
ptrdiff_t
to
,
EMACS_INT
tovpos
,
EMACS_INT
tohpos
,
EMACS_INT
width
,
ptrdiff_t
hscroll
,
int
tab_offset
,
struct
window
*
);
struct
position
*
vmotion
(
ptrdiff_t
from
,
ptrdiff_t
vtarget
,
struct
position
*
vmotion
(
ptrdiff_t
from
,
EMACS_INT
vtarget
,
struct
window
*
);
ptrdiff_t
skip_invisible
(
ptrdiff_t
pos
,
ptrdiff_t
*
next_boundary_p
,
ptrdiff_t
to
,
Lisp_Object
window
);
...
...
src/intervals.c
View file @
7c85f529
...
...
@@ -774,7 +774,7 @@ update_interval (register INTERVAL i, ptrdiff_t pos)
i
=
i
->
right
;
/* Move to the right child */
}
else
if
(
NULL_PARENT
(
i
))
error
(
"Point %"
p
I
"d after end of properties"
,
pos
);
error
(
"Point %"
p
D
"d after end of properties"
,
pos
);
else
i
=
INTERVAL_PARENT
(
i
);
continue
;
...
...
src/keyboard.c
View file @
7c85f529
...
...
@@ -6493,7 +6493,7 @@ modify_event_symbol (ptrdiff_t symbol_num, int modifiers, Lisp_Object symbol_kin
if (NILP (value))
{
char buf[sizeof "key-" + INT_STRLEN_BOUND (EMACS_INT)];
sprintf (buf, "key-%"p
I
"d", symbol_num);
sprintf (buf, "key-%"p
D
"d", symbol_num);
value = intern (buf);
}
...
...
src/print.c
View file @
7c85f529
...
...
@@ -1807,7 +1807,7 @@ print_object (Lisp_Object obj, register Lisp_Object printcharfun, int escapeflag
/* Implement a readable output, e.g.:
#s(hash-table size 2 test equal data (k1 v1 k2 v2)) */
/* Always print the size. */
sprintf
(
buf
,
"#s(hash-table size %"
p
I
"d"
,
ASIZE
(
h
->
next
));
sprintf
(
buf
,
"#s(hash-table size %"
p
D
"d"
,
ASIZE
(
h
->
next
));
strout
(
buf
,
-
1
,
-
1
,
printcharfun
);
if
(
!
NILP
(
h
->
test
))
...
...
@@ -1982,7 +1982,7 @@ print_object (Lisp_Object obj, register Lisp_Object printcharfun, int escapeflag
strout
(
"in no buffer"
,
-
1
,
-
1
,
printcharfun
);
else
{
sprintf
(
buf
,
"at %"
p
I
"d"
,
marker_position
(
obj
));
sprintf
(
buf
,
"at %"
p
D
"d"
,
marker_position
(
obj
));
strout
(
buf
,
-
1
,
-
1
,
printcharfun
);
strout
(
" in "
,
-
1
,
-
1
,
printcharfun
);
print_string
(
BVAR
(
XMARKER
(
obj
)
->
buffer
,
name
),
printcharfun
);
...
...
@@ -1996,7 +1996,7 @@ print_object (Lisp_Object obj, register Lisp_Object printcharfun, int escapeflag
strout
(
"in no buffer"
,
-
1
,
-
1
,
printcharfun
);
else
{
sprintf
(
buf
,
"from %"
p
I
"d to %"
p
I
"d in "
,
sprintf
(
buf
,
"from %"
p
D
"d to %"
p
D
"d in "
,
marker_position
(
OVERLAY_START
(
obj
)),
marker_position
(
OVERLAY_END
(
obj
)));
strout
(
buf
,
-
1
,
-
1
,
printcharfun
);
...
...
@@ -2035,7 +2035,7 @@ print_object (Lisp_Object obj, register Lisp_Object printcharfun, int escapeflag
if
(
MISCP
(
obj
))
sprintf
(
buf
,
"(MISC 0x%04x)"
,
(
int
)
XMISCTYPE
(
obj
));
else
if
(
VECTORLIKEP
(
obj
))
sprintf
(
buf
,
"(PVEC 0x%08"
p
I
"x)"
,
ASIZE
(
obj
));
sprintf
(
buf
,
"(PVEC 0x%08"
p
D
"x)"
,
ASIZE
(
obj
));
else
sprintf
(
buf
,
"(0x%02x)"
,
(
int
)
XTYPE
(
obj
));
strout
(
buf
,
-
1
,
-
1
,
printcharfun
);
...
...
src/syntax.c
View file @
7c85f529
...
...
@@ -2251,7 +2251,7 @@ between them, return t; otherwise return nil. */)
int
found
;
EMACS_INT
count1
;
ptrdiff_t
out_charpos
,
out_bytepos
;
ptrdiff_t
dummy
;
EMACS_INT
dummy
;
CHECK_NUMBER
(
count
);
count1
=
XINT
(
count
);
...
...
@@ -2473,7 +2473,7 @@ scan_lists (register EMACS_INT from, EMACS_INT count, EMACS_INT depth, int sexpf
ptrdiff_t
from_byte
;
ptrdiff_t
out_bytepos
,
out_charpos
;
int
temp
;
ptrdiff_t
dummy
;
EMACS_INT
dummy
;
int
multibyte_symbol_p
=
sexpflag
&&
multibyte_syntax_as_symbol
;
if
(
depth
>
0
)
min_depth
=
0
;
...
...
src/xdisp.c
View file @
7c85f529
...
...
@@ -20793,7 +20793,7 @@ decode_mode_spec (struct window *w, register int c, int field_width,
so get us a 2-digit number that is close. */
if (total == 100)
total = 99;
sprintf (decode_mode_spec_buf, "%2"p
I
"d%%", total);
sprintf (decode_mode_spec_buf, "%2"p
D
"d%%", total);
return decode_mode_spec_buf;
}
}
...
...
@@ -20824,9 +20824,9 @@ decode_mode_spec (struct window *w, register int c, int field_width,
if (total == 100)
total = 99;
if (toppos <= BUF_BEGV (b))
sprintf (decode_mode_spec_buf, "Top%2"p
I
"d%%", total);
sprintf (decode_mode_spec_buf, "Top%2"p
D
"d%%", total);
else
sprintf (decode_mode_spec_buf, "%2"p
I
"d%%", total);
sprintf (decode_mode_spec_buf, "%2"p
D
"d%%", total);
return decode_mode_spec_buf;
}
}
...
...
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