mirror of
https://github.com/python/cpython.git
synced 2025-07-07 19:35:27 +00:00
Issue #18722: Remove uses of the "register" keyword in C code.
This commit is contained in:
parent
9eaa3e6732
commit
9ed5f27266
38 changed files with 288 additions and 286 deletions
|
@ -92,11 +92,11 @@ static int digitlimit[] = {
|
|||
** exceptions - we don't check for them.
|
||||
*/
|
||||
unsigned long
|
||||
PyOS_strtoul(register char *str, char **ptr, int base)
|
||||
PyOS_strtoul(char *str, char **ptr, int base)
|
||||
{
|
||||
register unsigned long result = 0; /* return value of the function */
|
||||
register int c; /* current input character */
|
||||
register int ovlimit; /* required digits to overflow */
|
||||
unsigned long result = 0; /* return value of the function */
|
||||
int c; /* current input character */
|
||||
int ovlimit; /* required digits to overflow */
|
||||
|
||||
/* skip leading white space */
|
||||
while (*str && Py_ISSPACE(Py_CHARMASK(*str)))
|
||||
|
@ -213,7 +213,7 @@ PyOS_strtoul(register char *str, char **ptr, int base)
|
|||
if (ovlimit > 0) /* no overflow check required */
|
||||
result = result * base + c;
|
||||
else { /* requires overflow check */
|
||||
register unsigned long temp_result;
|
||||
unsigned long temp_result;
|
||||
|
||||
if (ovlimit < 0) /* guaranteed overflow */
|
||||
goto overflowed;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue