public inbox for gdb-cvs@sourceware.org
help / color / mirror / Atom feed
* [binutils-gdb] Remove a nullptr check in DWARF scanner
@ 2022-10-17 19:00 Tom Tromey
  0 siblings, 0 replies; only message in thread
From: Tom Tromey @ 2022-10-17 19:00 UTC (permalink / raw)
  To: gdb-cvs

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

commit 069355439fca1702c2440678663d1d0d40bbb735
Author: Tom Tromey <tromey@adacore.com>
Date:   Mon Oct 17 12:46:21 2022 -0600

    Remove a nullptr check in DWARF scanner
    
    In scan_attributes, The DWARF scanner checks whether maybe_defer is
    nullptr, but this can never happen.  This patch removes the check.

Diff:
---
 gdb/dwarf2/read.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/gdb/dwarf2/read.c b/gdb/dwarf2/read.c
index 33dfd52b362..b5efcb3cc09 100644
--- a/gdb/dwarf2/read.c
+++ b/gdb/dwarf2/read.c
@@ -18217,7 +18217,6 @@ cooked_indexer::scan_attributes (dwarf2_per_cu_data *scanning_per_cu,
 
 	  if (new_reader->cu == reader->cu
 	      && new_info_ptr > watermark_ptr
-	      && maybe_defer != nullptr
 	      && *parent_entry == nullptr)
 	    *maybe_defer = form_addr (origin_offset, origin_is_dwz);
 	  else if (*parent_entry == nullptr)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-10-17 19:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-17 19:00 [binutils-gdb] Remove a nullptr check in DWARF scanner Tom Tromey

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).