LLVM 20.0.0git
llvm::ilist_parent< ParentTy > Struct Template Reference

Option to add a pointer to this list's owner in every node. More...

#include "llvm/ADT/ilist_node_options.h"

Detailed Description

template<class ParentTy>
struct llvm::ilist_parent< ParentTy >

Option to add a pointer to this list's owner in every node.

This option causes the ilist_base_node for this list to contain a pointer ParentTy *Parent, returned by ilist_base_node::getNodeBaseParent() and set by ilist_base_node::setNodeBaseParent(ParentTy *Parent). The parent value is not set automatically; the ilist owner should set itself as the parent of the list sentinel, and the parent should be set on each node inserted into the list. This value is also not used by ilist_node_with_parent::getNodeParent(), but is used by ilist_iterator::getNodeParent(), which allows the parent to be fetched from any valid (non-null) iterator to this list, including the sentinel.

Definition at line 53 of file ilist_node_options.h.


The documentation for this struct was generated from the following file: