This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH c++ 6/6] aarch64: Add cast for integer to enum cast

/home/simark/src/binutils-gdb/gdb/aarch64-linux-tdep.c: In function âint aarch64_linux_syscall_record(regcache*, long unsigned int)â:
/home/simark/src/binutils-gdb/gdb/aarch64-linux-tdep.c:904:57: error: invalid conversion from âlong unsigned intâ to âaarch64_syscallâ [-fpermissive]
   syscall_gdb = aarch64_canonicalize_syscall (svc_number);
/home/simark/src/binutils-gdb/gdb/aarch64-linux-tdep.c:645:1: note:   initializing argument 1 of âgdb_syscall aarch64_canonicalize_syscall(aarch64_syscall)â
 aarch64_canonicalize_syscall (enum aarch64_syscall syscall_number)


	* aarch64-linux-tdep.c (aarch64_linux_syscall_record): Add cast.
 gdb/aarch64-linux-tdep.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gdb/aarch64-linux-tdep.c b/gdb/aarch64-linux-tdep.c
index 9c3500c..82c4b84 100644
--- a/gdb/aarch64-linux-tdep.c
+++ b/gdb/aarch64-linux-tdep.c
@@ -901,7 +901,8 @@ aarch64_linux_syscall_record (struct regcache *regcache,
   int ret = 0;
   enum gdb_syscall syscall_gdb;
-  syscall_gdb = aarch64_canonicalize_syscall (svc_number);
+  syscall_gdb =
+    aarch64_canonicalize_syscall ((enum aarch64_syscall) svc_number);
   if (syscall_gdb < 0)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]