This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
[patch] ld/lexsup.c: Remove an unused function, is_num().
- From: Kazu Hirata <kazu at cs dot umass dot edu>
- To: binutils at sources dot redhat dot com
- Date: Sat, 06 Dec 2003 11:29:40 -0500 (EST)
- Subject: [patch] ld/lexsup.c: Remove an unused function, is_num().
Hi,
Attached is a patch to remove an unused function, which was introduced
with the recent removal of mpc860c0 code.
Tested by building i686-pc-linux-gnu and h8300-elf. OK to apply?
Kazu Hirata
2003-12-06 Kazu Hirata <kazu@cs.umass.edu>
* lexsup.c (is_num): Remove.
Index: lexsup.c
===================================================================
RCS file: /cvs/src/src/ld/lexsup.c,v
retrieving revision 1.69
diff -u -r1.69 lexsup.c
--- lexsup.c 2 Dec 2003 05:58:11 -0000 1.69
+++ lexsup.c 6 Dec 2003 16:22:04 -0000
@@ -444,29 +444,6 @@
#define OPTION_COUNT ARRAY_SIZE (ld_options)
-/* Test STRING for containing a string of digits that form a number
- between MIN and MAX. The return value is the number or ERR. */
-
-static int
-is_num (const char *string, int min, int max, int err)
-{
- int result = 0;
-
- for (; *string; ++string)
- {
- if (! ISDIGIT (*string))
- {
- result = err;
- break;
- }
- result = result * 10 + (*string - '0');
- }
- if (result < min || result > max)
- result = err;
-
- return result;
-}
-
void
parse_args (unsigned argc, char **argv)
{