-
Notifications
You must be signed in to change notification settings - Fork 541
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cast ispace()/isdigit() args to int to remove warning
- Loading branch information
Showing
2 changed files
with
6 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
%option prefix="yy" | ||
%{ | ||
/* | ||
* Copyright (c) 1999-2024 Stephen Williams ([email protected]) | ||
* Copyright (c) 1999-2025 Stephen Williams ([email protected]) | ||
* | ||
* This source code is free software; you can redistribute it | ||
* and/or modify it in source code form under the terms of the GNU | ||
|
@@ -1080,17 +1080,17 @@ static void def_add_arg(void) | |
to us to chop it up to name and value. */ | ||
if ( (val=strchr(arg,'=')) ) { | ||
*val++ = 0; | ||
while (*val && isspace(*val)) val += 1; | ||
while (*val && isspace((int)*val)) val += 1; | ||
|
||
val_length = strlen(val); | ||
while (val_length>0 && isspace(val[val_length-1])) { | ||
while (val_length>0 && isspace((int)val[val_length-1])) { | ||
val_length -= 1; | ||
val[val_length] = 0; | ||
} | ||
|
||
/* Strip white space from between arg and "=". */ | ||
length = strlen(arg); | ||
while (length>0 && isspace(arg[length-1])) { | ||
while (length>0 && isspace((int)arg[length-1])) { | ||
length -= 1; | ||
arg[length] = 0; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
* Copyright (c) 2012-2021 Stephen Williams ([email protected]) | ||
* Copyright (c) 2012-2025 Stephen Williams ([email protected]) | ||
* | ||
* This source code is free software; you can redistribute it | ||
* and/or modify it in source code form under the terms of the GNU | ||
|
@@ -151,7 +151,7 @@ static PLI_INT32 atoi_calltf(ICARUS_VPI_CONST PLI_BYTE8*name) | |
vpi_get_value(arg, &value); | ||
const char*bufp = value.value.str; | ||
while (bufp && *bufp) { | ||
if (isdigit(*bufp)) { | ||
if (isdigit((int)*bufp)) { | ||
res = (res * 10) + (*bufp - '0'); | ||
bufp += 1; | ||
} else if (*bufp == '_') { | ||
|