Patchwork [2/2] Remove unused includes in aarch64-linux-tdep.c

login
register
mail settings
Submitter Simon Marchi
Date Dec. 3, 2019, 4:25 a.m.
Message ID <20191203042558.2694627-2-simon.marchi@polymtl.ca>
Download mbox | patch
Permalink /patch/36453/
State New
Headers show

Comments

Simon Marchi - Dec. 3, 2019, 4:25 a.m.
include-what-you-use reports:

../../../src/binutils-gdb/gdb/aarch64-linux-tdep.c should remove these lines:
- #include "arch-utils.h"  // lines 24-24
- #include "auxv.h"  // lines 48-48
- #include "cli/cli-utils.h"  // lines 39-39
- #include "elf/common.h"  // lines 49-49
- #include "inferior.h"  // lines 35-35

Add an include for "target/target.h", otherwise target_read_memory isn't
found.

gdb/ChangeLog:

	* aarch64-linux-tdep.c: Remove includes.
---
 gdb/aarch64-linux-tdep.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

Patch

diff --git a/gdb/aarch64-linux-tdep.c b/gdb/aarch64-linux-tdep.c
index c8e30a4fef24..1d4aac7a8743 100644
--- a/gdb/aarch64-linux-tdep.c
+++ b/gdb/aarch64-linux-tdep.c
@@ -21,7 +21,6 @@ 
 #include "defs.h"
 
 #include "gdbarch.h"
-#include "arch-utils.h"
 #include "glibc-tdep.h"
 #include "linux-tdep.h"
 #include "aarch64-tdep.h"
@@ -31,12 +30,11 @@ 
 #include "symtab.h"
 #include "tramp-frame.h"
 #include "trad-frame.h"
+#include "target/target.h"
 
-#include "inferior.h"
 #include "regcache.h"
 #include "regset.h"
 
-#include "cli/cli-utils.h"
 #include "stap-probe.h"
 #include "parser-defs.h"
 #include "user-regs.h"
@@ -45,8 +43,6 @@ 
 
 #include "record-full.h"
 #include "linux-record.h"
-#include "auxv.h"
-#include "elf/common.h"
 
 /* Signal frame handling.