summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Modra <amodra@bigpond.net.au>2005-11-06 23:04:10 +0000
committerAlan Modra <amodra@bigpond.net.au>2005-11-06 23:04:10 +0000
commit5fd4c57f7e1fc89b7af8be447c20b8e32fda19e4 (patch)
treee1ce41626163826b334f3f3856ae39427b2d3944
parent638b15646a17211730ead7e7605000c69f9dcefa (diff)
downloadbinutils-redhat-5fd4c57f7e1fc89b7af8be447c20b8e32fda19e4.tar.gz
* expr.c (integer_constant): Match only 'B' as binary suffix if
NUMBERS_WITH_SUFFIX and LOCAL_LABELS_FB. Allow both 'b' and 'B' otherwise.
-rw-r--r--gas/ChangeLog6
-rw-r--r--gas/expr.c5
2 files changed, 10 insertions, 1 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 9313163a63..5e503fefd1 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,9 @@
+2005-11-07 Arnold Metselaar <arnold.metselaar@planet.nl>
+
+ * expr.c (integer_constant): Match only 'B' as binary suffix if
+ NUMBERS_WITH_SUFFIX and LOCAL_LABELS_FB. Allow both 'b' and 'B'
+ otherwise.
+
2005-11-04 Alexandre Oliva <aoliva@redhat.com>
* read.c (s_weakref): Do not permit redefinitions.
diff --git a/gas/expr.c b/gas/expr.c
index 32de0f7394..0664e29d28 100644
--- a/gas/expr.c
+++ b/gas/expr.c
@@ -301,7 +301,10 @@ integer_constant (int radix, expressionS *expressionP)
{
c = *--suffix;
c = TOUPPER (c);
- if (c == 'B')
+ /* If we have both NUMBERS_WITH_SUFFIX and LOCAL_LABELS_FB,
+ we distinguish between 'B' and 'b'. This is the case for
+ Z80. */
+ if ((NUMBERS_WITH_SUFFIX && LOCAL_LABELS_FB ? *suffix : c) == 'B')
radix = 2;
else if (c == 'D')
radix = 10;