aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@suse.com>2025-02-03 12:29:29 +0100
committerJan Beulich <jbeulich@suse.com>2025-02-03 12:29:29 +0100
commit716680bc55e22dbf01a78cce903e7bb262a1aa7e (patch)
tree952ebfc83eb0de586e292995c6ec37802caf8f44
parent52ea980d007540d36f3261487a93151c79e89b68 (diff)
downloadbinutils-716680bc55e22dbf01a78cce903e7bb262a1aa7e.zip
binutils-716680bc55e22dbf01a78cce903e7bb262a1aa7e.tar.gz
binutils-716680bc55e22dbf01a78cce903e7bb262a1aa7e.tar.bz2
Z80: use is_whitespace()
Replace an open-coded check and convert ISSPACE() uses.
-rw-r--r--gas/config/tc-z80.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gas/config/tc-z80.c b/gas/config/tc-z80.c
index 3805e32..3abc026 100644
--- a/gas/config/tc-z80.c
+++ b/gas/config/tc-z80.c
@@ -582,7 +582,7 @@ z80_elf_final_processing (void)
static const char *
skip_space (const char *s)
{
- while (*s == ' ' || *s == '\t')
+ while (is_whitespace (*s))
++s;
return s;
}
@@ -623,7 +623,7 @@ z80_start_line_hook (void)
case '#': /* force to use next expression as immediate value in SDCC */
if (!sdcc_compat)
break;
- if (ISSPACE(p[1]) && *skip_space (p + 1) == '(')
+ if (is_whitespace (p[1]) && *skip_space (p + 1) == '(')
{ /* ld a,# (expr)... -> ld a,0+(expr)... */
*p++ = '0';
*p = '+';
@@ -3384,7 +3384,7 @@ assemble_suffix (const char **suffix)
for (i = 0; (i < 3) && (ISALPHA (*p)); i++)
sbuf[i] = TOLOWER (*p++);
- if (*p && !ISSPACE (*p))
+ if (*p && !is_whitespace (*p))
return 0;
*suffix = p;
sbuf[i] = 0;
@@ -3670,7 +3670,7 @@ md_assemble (char *str)
else
{
dwarf2_emit_insn (0);
- if ((*p) && (!ISSPACE (*p)))
+ if ((*p) && !is_whitespace (*p))
{
if (*p != '.' || !(ins_ok & INS_EZ80) || !assemble_suffix (&p))
{