slang::syntax::SyntaxNode::ParentRef class

A small proxy that behaves like a SyntaxNode* but stores its pointer in a tagged form so that the low bit can be used to indicate the rare presence of a "preview node" attached to this node (see previewNode() below).

When the low bit is clear, the stored value is a plain pointer to the parent SyntaxNode. When set, the value points instead at a detail::SyntaxParentInfo struct (allocated from the same BumpAllocator that owns the syntax tree) which holds both the real parent pointer and the preview node pointer.