diff options
| author | KaiStevenson <kai@kaistevenson.com> | 2023-03-04 14:37:05 -0800 |
|---|---|---|
| committer | KaiStevenson <kai@kaistevenson.com> | 2023-03-04 14:37:05 -0800 |
| commit | 4ece2801b980358ed0a81efb78b4c4cadee03f6e (patch) | |
| tree | 050152bf2af0cbca0fd31fbbdee38d21b05e3e6a /src/parse.c | |
| parent | 2127b746f0eecb657b31653ad5967623f994cbaf (diff) | |
fixed compiler warnings on windows
Diffstat (limited to 'src/parse.c')
| -rw-r--r-- | src/parse.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/parse.c b/src/parse.c index f8749ac..b7596d4 100644 --- a/src/parse.c +++ b/src/parse.c @@ -82,7 +82,7 @@ symset_t* parse_symbols(char** str, int* sLine) { symbolSet->count = 0; while (1) { /* clear whitespace */ - while (!isalnum(**str) && **str != '"' && **str != '-' && **str != '(' && **str != ')' && **str != '\0') { + while (!isalnum((unsigned char)**str) && **str != '"' && **str != '-' && **str != '(' && **str != ')' && **str != '\0') { /* increment line counter if newline read */ if (**str == '\n') { (*sLine)++; @@ -126,7 +126,7 @@ symset_t* parse_symbols(char** str, int* sLine) { isFloat = 1; } /* we've hit a character that cannot be part of the symbol. parse the prior characters as the symbol name */ - else if (!isalnum(**str) && **str != '-' && **str != '(') { + else if (!isalnum((unsigned char)**str) && **str != '-' && **str != '(') { /* move the pointer back, because the close paren is needed to return the calling function */ if (**str == ')') { (*str)--; @@ -134,7 +134,7 @@ symset_t* parse_symbols(char** str, int* sLine) { (*str)++; symbolName[i] = '\0'; sym_t* symbol; - if (isalpha(symbolName[0])) { + if (isalpha((unsigned int)symbolName[0])) { /* reference */ symbol = init_sym_key(symbolName); } |
