<div dir="ltr"><div dir="ltr"><br></div><div dir="ltr"><div dir="ltr">On Wed, Aug 28, 2019 at 8:16 PM Ville Voutilainen &lt;<a href="mailto:ville.voutilainen@gmail.com" target="_blank">ville.voutilainen@gmail.com</a>&gt; wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Wed, 28 Aug 2019 at 07:18, Andrew Tomazos via Lib-Ext<br>
&lt;<a href="mailto:lib-ext@lists.isocpp.org" target="_blank">lib-ext@lists.isocpp.org</a>&gt; wrote:<br>
&gt;<br>
&gt; I think modelling a path as a container of its components is reasonable.<br>
&gt;<br>
&gt; What isn&#39;t reasonable is that those components are themselves paths, as this would imply that the value of a single-component path P is a container of one item, and that one item contained in P has the value P.  A container shouldn&#39;t be able to contain itself.  It&#39;s nonsensical.<br>
<br>
It&#39;s perfectly sensical for hierarchical things</blockquote><div><br></div><div>Consider:</div><div><br></div><div>    struct Tree {</div><div>        std::vector&lt;Tree&gt; children;</div><div>    };</div><div><br>    bool operator==(const Tree&amp; a, const Tree&amp; b) {</div><div>        return a.children == b.children;</div><div>    }<br></div><div><br></div><div>Here we have a type that is a container of itself.  A hierarchy.</div><div><br></div><div>However, there is no *value* of type Tree such that:</div><div><br></div><div>    *this == this-&gt;children[0]</div><div><br></div><div>I would argue hierarchy alone is not a sufficient motivation to have a self-referential model such that a *value* can be a container holding itself.</div><div><br></div><div>You would need to be modelling something that needs a cyclic directed graph - but even then we don&#39;t often think of a graph node as being a &quot;container&quot; of its outbound edges.</div><div><br></div></div></div>
</div>