This is the mail archive of the binutils-cvs@sourceware.org mailing list for the binutils 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]

[binutils-gdb] Mark big and mach with ATTRIBUTE_UNUSED


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=b28b8b5e31903f59b00a4664b8204409e1e5bb91

commit b28b8b5e31903f59b00a4664b8204409e1e5bb91
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Aug 7 08:07:26 2017 -0700

    Mark big and mach with ATTRIBUTE_UNUSED
    
    Fix build on x86:
    
    opcodes/disassemble.c: In function â??disassemblerâ??:
    opcodes/disassemble.c:113:52: error: unused parameter â??bigâ?? [-Werror=unused-parameter]
     disassembler (enum bfd_architecture a, bfd_boolean big, unsigned long mach,
                                                        ^~~
    opcodes/disassemble.c:113:71: error: unused parameter â??machâ?? [-Werror=unused-parameter]
     disassembler (enum bfd_architecture a, bfd_boolean big, unsigned long mach,
                                                                           ^~~~
    cc1: all warnings being treated as errors
    
    	* disassemble.c (disassembler): Mark big and mach with
    	ATTRIBUTE_UNUSED.

Diff:
---
 opcodes/ChangeLog     | 5 +++++
 opcodes/disassemble.c | 4 +++-
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index 61572dd..4414037 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -1,3 +1,8 @@
+2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* disassemble.c (disassembler): Mark big and mach with
+	ATTRIBUTE_UNUSED.
+
 2017-08-07  Maciej W. Rozycki  <macro@imgtec.com>
 
 	* disassemble.c (disassembler): Remove arch/mach/endian
diff --git a/opcodes/disassemble.c b/opcodes/disassemble.c
index 0058354..11206c6 100644
--- a/opcodes/disassemble.c
+++ b/opcodes/disassemble.c
@@ -110,7 +110,9 @@
 #endif
 
 disassembler_ftype
-disassembler (enum bfd_architecture a, bfd_boolean big, unsigned long mach,
+disassembler (enum bfd_architecture a,
+	      bfd_boolean big ATTRIBUTE_UNUSED,
+	      unsigned long mach ATTRIBUTE_UNUSED,
 	      bfd *abfd ATTRIBUTE_UNUSED)
 {
   disassembler_ftype disassemble;


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