Mercurial > hg > xemacs-beta
comparison src/doprnt.c @ 647:b39c14581166
[xemacs-hg @ 2001-08-13 04:45:47 by ben]
removal of unsigned, size_t, etc.
author | ben |
---|---|
date | Mon, 13 Aug 2001 04:46:48 +0000 |
parents | 910449c92002 |
children | fdefd0186b75 |
comparison
equal
deleted
inserted
replaced
646:00c54252fe4f | 647:b39c14581166 |
---|---|
127 REGISTER Bufbyte *arg_ptr = arg_convert; | 127 REGISTER Bufbyte *arg_ptr = arg_convert; |
128 | 128 |
129 *returned_num = -1; | 129 *returned_num = -1; |
130 while (start != end && isdigit (*start)) | 130 while (start != end && isdigit (*start)) |
131 { | 131 { |
132 if ((size_t) (arg_ptr - arg_convert) >= sizeof (arg_convert) - 1) | 132 if (arg_ptr - arg_convert >= (int) sizeof (arg_convert) - 1) |
133 syntax_error ("Format converter number too large", Qunbound); | 133 syntax_error ("Format converter number too large", Qunbound); |
134 *arg_ptr++ = *start++; | 134 *arg_ptr++ = *start++; |
135 } | 135 } |
136 *arg_ptr = '\0'; | 136 *arg_ptr = '\0'; |
137 if (arg_convert != arg_ptr) | 137 if (arg_convert != arg_ptr) |
138 *returned_num = atoi ((char *) arg_convert); | 138 *returned_num = atoi ((char *) arg_convert); |
596 /* ASCII Decimal representation uses 2.4 times as many | 596 /* ASCII Decimal representation uses 2.4 times as many |
597 bits as machine binary. */ | 597 bits as machine binary. */ |
598 char *text_to_print = | 598 char *text_to_print = |
599 alloca_array (char, 32 + | 599 alloca_array (char, 32 + |
600 max (spec->minwidth, | 600 max (spec->minwidth, |
601 max (sizeof (double), sizeof (long)) * 3 + | 601 (int) max (sizeof (double), |
602 sizeof (long)) * 3 + | |
602 max (spec->precision, 0))); | 603 max (spec->precision, 0))); |
603 char constructed_spec[100]; | 604 char constructed_spec[100]; |
604 char *p = constructed_spec; | 605 char *p = constructed_spec; |
605 | 606 |
606 /* Mostly reconstruct the spec and use sprintf() to | 607 /* Mostly reconstruct the spec and use sprintf() to |