Commit 57ace6d0 authored by Paul Eggert's avatar Paul Eggert
Browse files

* data.c etc: conform to C89 pointer rules

parent cca94728
......@@ -9,6 +9,8 @@
* search.c (Freplace_match, Fregexp_quote): Likewise.
* alloc.c (make_string, make_specified_string, make_pure_string):
Likewise.
* data.c (Fstring_to_number): Likewise.
* print.c (float_to_string): Likewise.
 
2011-02-06 Paul Eggert <eggert@cs.ucla.edu>
 
......@@ -2417,7 +2417,7 @@ present, base 10 is used. BASE must be between 2 and 16 (inclusive).
If the base used is not 10, STRING is always parsed as integer. */)
(register Lisp_Object string, Lisp_Object base)
{
register unsigned char *p;
register char *p;
register int b;
int sign = 1;
Lisp_Object val;
......@@ -2436,7 +2436,7 @@ If the base used is not 10, STRING is always parsed as integer. */)
/* Skip any whitespace at the front of the number. Some versions of
atoi do this anyway, so we might as well make Emacs lisp consistent. */
p = SDATA (string);
p = SSDATA (string);
while (*p == ' ' || *p == '\t')
p++;
......@@ -3334,4 +3334,3 @@ init_data (void)
signal (SIGEMT, arith_error);
#endif /* uts */
}
......@@ -2787,7 +2787,7 @@ extern void print_error_message (Lisp_Object, Lisp_Object, const char *,
extern Lisp_Object internal_with_output_to_temp_buffer
(const char *, Lisp_Object (*) (Lisp_Object), Lisp_Object);
#define FLOAT_TO_STRING_BUFSIZE 350
extern void float_to_string (unsigned char *, double);
extern void float_to_string (char *, double);
extern void syms_of_print (void);
/* Defined in doprnt.c */
......
......@@ -1016,9 +1016,9 @@ print_error_message (Lisp_Object data, Lisp_Object stream, const char *context,
*/
void
float_to_string (unsigned char *buf, double data)
float_to_string (char *buf, double data)
{
unsigned char *cp;
char *cp;
int width;
/* Check for plus infinity in a way that won't lose
......@@ -1067,7 +1067,7 @@ float_to_string (unsigned char *buf, double data)
/* Check that the spec we have is fully valid.
This means not only valid for printf,
but meant for floats, and reasonable. */
cp = SDATA (Vfloat_output_format);
cp = SSDATA (Vfloat_output_format);
if (cp[0] != '%')
goto lose;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment