]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Remove unused methods from buildsym_compunit
authorTom Tromey <tom@tromey.com>
Sun, 18 Jan 2026 17:26:02 +0000 (10:26 -0700)
committerTom Tromey <tom@tromey.com>
Tue, 20 Jan 2026 02:44:07 +0000 (19:44 -0700)
A few methods of buildsym_compunit are now unused and can be removed.

Approved-By: Simon Marchi <simon.marchi@efficios.com>
gdb/buildsym.c
gdb/buildsym.h

index 3c1d6f84ce9e6112101fea3d4f363eb2c591796a..f7386de8d38d02275795a26d08af33bc8a509aec 100644 (file)
@@ -478,27 +478,6 @@ buildsym_compunit::start_subfile (const char *name, const char *name_for_id)
   m_subfiles = subfile.release ();
 }
 
-/* Handle the N_BINCL and N_EINCL symbol types that act like N_SOL for
-   switching source files (different subfiles, as we call them) within
-   one object file, but using a stack rather than in an arbitrary
-   order.  */
-
-void
-buildsym_compunit::push_subfile ()
-{
-  gdb_assert (m_current_subfile != NULL);
-  gdb_assert (!m_current_subfile->name.empty ());
-  m_subfile_stack.push_back (m_current_subfile->name.c_str ());
-}
-
-const char *
-buildsym_compunit::pop_subfile ()
-{
-  gdb_assert (!m_subfile_stack.empty ());
-  const char *name = m_subfile_stack.back ();
-  m_subfile_stack.pop_back ();
-  return name;
-}
 \f
 /* Add a linetable entry for line number LINE and address PC to the
    line vector for SUBFILE.  */
index 3ed4bd5f5332eb787a18c8ee490dec7a60734154..2ec7e47d4931b3a5645191974d65be30fc71519f 100644 (file)
@@ -198,17 +198,6 @@ struct buildsym_compunit
      existing subfiles).  It can be equal to NAME if NAME follows that rule.  */
   void start_subfile (const char *name, const char *name_for_id);
 
-  /* Same as above, but passes NAME for NAME_FOR_ID.  */
-
-  void start_subfile (const char *name)
-  {
-    return start_subfile (name, name);
-  }
-
-  void push_subfile ();
-
-  const char *pop_subfile ();
-
   void record_line (struct subfile *subfile, int line, unrelocated_addr pc,
                    linetable_entry_flags flags);