Sophie

Sophie

distrib > Mageia > 7 > x86_64 > by-pkgid > 96c6fcad26b4c60fa9809f334cafc603 > files > 3

binutils-2.33.1-1.mga7.src.rpm

From c06868784d819a45c43947180c69e168aecaf368 Mon Sep 17 00:00:00 2001
From: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date: Mon, 21 Oct 2019 16:59:11 +0100
Subject: [PATCH] [ARM][gas] fix build breakage with gcc-10 by using correct
 enum type

Fixes

../../gas/config/tc-arm.c: In function 'parse_reg_list':
../../gas/config/tc-arm.c:1946:35: error: implicit conversion from 'enum reg_list_els' to 'enum arm_reg_type' [-Werror=enum-conversion]
 1946 |        reg = arm_reg_parse (&str, REGLIST_RN);
      |                                   ^~~~~~~~~~

gas/ChangeLog:

	Backported from mainline.
	2020-01-02  Szabolcs Nagy  <szabolcs.nagy@arm.com>

	* config/tc-arm.c (parse_reg_list): Use REG_TYPE_RN instead of
	REGLIST_RN.
---
 gas/ChangeLog       | 8 ++++++++
 gas/config/tc-arm.c | 2 +-
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/gas/ChangeLog b/gas/ChangeLog
index fcb5592f9f..81f066d6d7 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,11 @@
+2020-01-13  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	Backported from mainline.
+	2020-01-02  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* config/tc-arm.c (parse_reg_list): Use REG_TYPE_RN instead of
+	REGLIST_RN.
+
 2019-12-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
 
 	Backported from mainline.
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index caabdbba90..9910572fd9 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -1868,7 +1868,7 @@ parse_reg_list (char ** strp, enum reg_list_els etype)
 	      const char apsr_str[] = "apsr";
 	      int apsr_str_len = strlen (apsr_str);
 
-	      reg = arm_reg_parse (&str, REGLIST_RN);
+	      reg = arm_reg_parse (&str, REG_TYPE_RN);
 	      if (etype == REGLIST_CLRM)
 		{
 		  if (reg == REG_SP || reg == REG_PC)
-- 
2.25.1