<div dir="ltr">I was treating this as a Mixin.<div><br></div><div>So the property from Object is Mixed into Tree and User but it isn&#39;t a Subclass so any comparison between the two isn&#39;t possible.</div><div><br></div><div>But on reflection you bring up a very valid point.</div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr">







<p><b><font color="#cc0000">___________________________________</font></b></p><p><b>James⎥Head Of CEO</b></p><p><b><font color="#cc0000"><a href="mailto:james@supmenow.com" target="_blank">james@supmenow.com</a>⎥<a href="http://supmenow.com" target="_blank">supmenow.com</a></font></b></p><p><b><font size="2">Sup</font></b></p><p><b><font size="2">Runway East
</font></b></p><p><b><font size="2">10 Finsbury Square</font></b></p><p><b><font size="2">London</font></b></p><p><b><font size="2">
EC2A 1AF </font></b></p></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div>
<br><div class="gmail_quote">On Thu, Mar 24, 2016 at 5:34 PM, Tino Heth <span dir="ltr">&lt;<a href="mailto:2th@gmx.de" target="_blank">2th@gmx.de</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><span class=""><div><blockquote type="cite"><div><div dir="ltr" style="font-family:Helvetica;font-size:12px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><div>struct Object {</div><div>let identifier: String</div><div>}</div><div><br></div><div>struct User: Object {</div><div><br></div><div>}</div><div><br></div><div>struct Tree: Object {</div><div>}</div><div><br></div><div>The last two structs get the identifier property &quot;mixed&quot; in but are unique types :)</div></div></div></blockquote></div><br></span><div>Is unique meant so that User-Objects can&#39;t be used as &quot;Object&quot;-Object parameters?</div><div>I&#39;m asking because this might be the biggest source of confusion with struct inheritance:</div><div>As the two &quot;child-structs&quot; don&#39;t add new data to their parent, they would (technically) be compatible — but this is fragile, so it might be preferable to &quot;hide&quot; polymorphism by default, and maybe add an annotation to explicitly allow that a sub-struct can be used as its parent type.</div><div>@compatible(Float) struct SpecialFloat: Float...</div><div><br></div></div></blockquote></div><br></div>