aboutsummaryrefslogtreecommitdiff
path: root/binutils/nlmheader.y
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2001-09-19 05:33:36 +0000
committerH.J. Lu <hjl.tools@gmail.com>2001-09-19 05:33:36 +0000
commit3882b010780ca1aa1ed5d7b38e936cd2d6d5486b (patch)
treec806a73a13afd3265ba6b538ba73cae065c591f5 /binutils/nlmheader.y
parent6b819c92c4512ccfba90f0caa204ab687fae8254 (diff)
downloadgdb-3882b010780ca1aa1ed5d7b38e936cd2d6d5486b.zip
gdb-3882b010780ca1aa1ed5d7b38e936cd2d6d5486b.tar.gz
gdb-3882b010780ca1aa1ed5d7b38e936cd2d6d5486b.tar.bz2
Locale changes from Bruno Haible <haible@clisp.cons.org>.
Diffstat (limited to 'binutils/nlmheader.y')
-rw-r--r--binutils/nlmheader.y21
1 files changed, 9 insertions, 12 deletions
diff --git a/binutils/nlmheader.y b/binutils/nlmheader.y
index 3ab5a79..5d83f31 100644
--- a/binutils/nlmheader.y
+++ b/binutils/nlmheader.y
@@ -1,5 +1,5 @@
%{/* nlmheader.y - parse NLM header specification keywords.
- Copyright 1993, 1994, 1995, 1997, 1998 Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1997, 1998, 2001 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -28,7 +28,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <ansidecl.h>
#include <stdio.h>
-#include <ctype.h>
+#include "safe-ctype.h"
#include "bfd.h"
#include "bucomm.h"
#include "nlm/common.h"
@@ -682,7 +682,7 @@ tail_recurse:
c = getc (current.file);
/* Commas are treated as whitespace characters. */
- while (isspace ((unsigned char) c) || c == ',')
+ while (ISSPACE (c) || c == ',')
{
current.state = IN_LINE;
if (c == '\n')
@@ -735,9 +735,9 @@ tail_recurse:
if (c == '\n')
++current.lineno;
}
- while (isspace ((unsigned char) c));
+ while (ISSPACE (c));
BUF_INIT ();
- while (! isspace ((unsigned char) c) && c != EOF)
+ while (! ISSPACE (c) && c != EOF)
{
BUF_ADD (c);
c = getc (current.file);
@@ -755,17 +755,14 @@ tail_recurse:
if (current.state == BEGINNING_OF_LINE)
{
BUF_INIT ();
- while (isalnum ((unsigned char) c) || c == '_')
+ while (ISALNUM (c) || c == '_')
{
- if (islower ((unsigned char) c))
- BUF_ADD (toupper ((unsigned char) c));
- else
- BUF_ADD (c);
+ BUF_ADD (TOUPPER (c));
c = getc (current.file);
}
BUF_FINISH ();
- if (c != EOF && ! isspace ((unsigned char) c) && c != ',')
+ if (c != EOF && ! ISSPACE (c) && c != ',')
{
nlmheader_identify ();
fprintf (stderr, _("%s:%d: illegal character in keyword: %c\n"),
@@ -838,7 +835,7 @@ tail_recurse:
/* Gather a generic argument. */
BUF_INIT ();
- while (! isspace (c)
+ while (! ISSPACE (c)
&& c != ','
&& c != COMMENT_CHAR
&& c != '('