[Lldb-commits] [lldb] [lldb] Make sure Blocks always have a parent (PR #117683)

David Spickett via lldb-commits lldb-commits at lists.llvm.org
Tue Nov 26 01:26:20 PST 2024


================
@@ -43,11 +43,13 @@ class Block : public UserID, public SymbolContextScope {
   typedef RangeVector<uint32_t, uint32_t, 1> RangeList;
   typedef RangeList::Entry Range;
 
-  /// Construct with a User ID \a uid, \a depth.
-  ///
-  /// Initialize this block with the specified UID \a uid. The \a depth in the
-  /// \a block_list is used to represent the parent, sibling, and child block
-  /// information and also allows for partial parsing at the block level.
+  // Creates a block representing the whole function. Only meant to be used from
+  // the Function class.
----------------
DavidSpickett wrote:

Can you enforce that restriction using `friend`, or does it get into a mess of circular includes?

https://github.com/llvm/llvm-project/pull/117683


More information about the lldb-commits mailing list