public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: gdb-patches@sourceware.org
Cc: Tom Tromey <tom@tromey.com>
Subject: [PATCH] Remove some unnecessary includes from *-exp.y
Date: Sat, 18 Mar 2023 08:44:50 -0600	[thread overview]
Message-ID: <20230318144450.1928512-1-tom@tromey.com> (raw)

I noticed a weird comment in one of the .y files, and then ended up
removing some unnecessary #includes from these files.

Tested by rebuilding.
---
 gdb/ada-exp.y | 3 ---
 gdb/c-exp.y   | 3 ---
 gdb/d-exp.y   | 3 ---
 gdb/f-exp.y   | 3 ---
 gdb/go-exp.y  | 3 ---
 gdb/m2-exp.y  | 3 ---
 gdb/p-exp.y   | 4 ----
 7 files changed, 22 deletions(-)

diff --git a/gdb/ada-exp.y b/gdb/ada-exp.y
index 9b704968f90..a9c37bedff0 100644
--- a/gdb/ada-exp.y
+++ b/gdb/ada-exp.y
@@ -42,9 +42,6 @@
 #include "parser-defs.h"
 #include "language.h"
 #include "ada-lang.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols */
 #include "frame.h"
 #include "block.h"
 #include "ada-exp.h"
diff --git a/gdb/c-exp.y b/gdb/c-exp.y
index 00599b0da7f..9ee4115560a 100644
--- a/gdb/c-exp.y
+++ b/gdb/c-exp.y
@@ -43,9 +43,6 @@
 #include "language.h"
 #include "c-lang.h"
 #include "c-support.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols */
 #include "charset.h"
 #include "block.h"
 #include "cp-support.h"
diff --git a/gdb/d-exp.y b/gdb/d-exp.y
index 1c299bf7ac6..3a4e7ee0434 100644
--- a/gdb/d-exp.y
+++ b/gdb/d-exp.y
@@ -46,9 +46,6 @@
 #include "language.h"
 #include "c-lang.h"
 #include "d-lang.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols */
 #include "charset.h"
 #include "block.h"
 #include "type-stack.h"
diff --git a/gdb/f-exp.y b/gdb/f-exp.y
index 30da537ea84..96d38af363c 100644
--- a/gdb/f-exp.y
+++ b/gdb/f-exp.y
@@ -48,9 +48,6 @@
 #include "parser-defs.h"
 #include "language.h"
 #include "f-lang.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols */
 #include "block.h"
 #include <ctype.h>
 #include <algorithm>
diff --git a/gdb/go-exp.y b/gdb/go-exp.y
index 6aa4c426df6..542a06d06d6 100644
--- a/gdb/go-exp.y
+++ b/gdb/go-exp.y
@@ -59,9 +59,6 @@
 #include "language.h"
 #include "c-lang.h"
 #include "go-lang.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols */
 #include "charset.h"
 #include "block.h"
 #include "expop.h"
diff --git a/gdb/m2-exp.y b/gdb/m2-exp.y
index 6629974a73e..092a8be248d 100644
--- a/gdb/m2-exp.y
+++ b/gdb/m2-exp.y
@@ -43,9 +43,6 @@
 #include "value.h"
 #include "parser-defs.h"
 #include "m2-lang.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols */
 #include "block.h"
 #include "m2-exp.h"
 
diff --git a/gdb/p-exp.y b/gdb/p-exp.y
index b5251b932ef..b086bf73a0e 100644
--- a/gdb/p-exp.y
+++ b/gdb/p-exp.y
@@ -50,11 +50,7 @@
 #include "parser-defs.h"
 #include "language.h"
 #include "p-lang.h"
-#include "bfd.h" /* Required by objfiles.h.  */
-#include "symfile.h" /* Required by objfiles.h.  */
-#include "objfiles.h" /* For have_full_symbols and have_partial_symbols.  */
 #include "block.h"
-#include "completer.h"
 #include "expop.h"
 
 #define parse_type(ps) builtin_type (ps->gdbarch ())
-- 
2.39.1


             reply	other threads:[~2023-03-18 14:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-18 14:44 Tom Tromey [this message]
2023-03-20 15:45 ` Simon Marchi
2023-03-20 21:22   ` Tom Tromey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230318144450.1928512-1-tom@tromey.com \
    --to=tom@tromey.com \
    --cc=gdb-patches@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).