[1/2] gdb/dwarf: add doc for cutu_reader::is_dummy

Message ID 20250308030246.1036109-1-simon.marchi@polymtl.ca
State New
Headers
Series [1/2] gdb/dwarf: add doc for cutu_reader::is_dummy |

Checks

Context Check Description
linaro-tcwg-bot/tcwg_gdb_build--master-aarch64 fail Patch failed to apply
linaro-tcwg-bot/tcwg_gdb_build--master-arm fail Patch failed to apply

Commit Message

Simon Marchi March 8, 2025, 3:02 a.m. UTC
  From: Simon Marchi <simon.marchi@polymtl.ca>

Change-Id: Ifb80557187c12822bdea7ad400c32c3dce968a7f
---
 gdb/dwarf2/read.h | 5 +++++
 1 file changed, 5 insertions(+)


base-commit: 86a53c0b2ead2d0da2a6bf91741c705df6b97f76
  

Comments

Tom Tromey March 10, 2025, 3:09 p.m. UTC | #1
>>>>> "Simon" == simon marchi <simon.marchi@polymtl.ca> writes:

Simon> From: Simon Marchi <simon.marchi@polymtl.ca>
Simon> Change-Id: Ifb80557187c12822bdea7ad400c32c3dce968a7f

Ok.  Thanks for doing this.
Approved-By: Tom Tromey <tom@tromey.com>

Tom
  

Patch

diff --git a/gdb/dwarf2/read.h b/gdb/dwarf2/read.h
index b6ff433978c3..d6d119e038dc 100644
--- a/gdb/dwarf2/read.h
+++ b/gdb/dwarf2/read.h
@@ -945,6 +945,11 @@  class cutu_reader
 
   cutu_reader (cutu_reader &&) = default;
 
+  /* Return true if either:
+
+      - the unit is empty (just a header without any DIE)
+      - the unit is a partial unit and this cutu_reader was built with SKIP
+	PARTIAL true.  */
   bool is_dummy () const { return m_dummy_p; }
 
   dwarf2_cu *cu () const { return m_cu; }