<html><body bgcolor="#FFFFFF"><div>I thought Henry's question was with regard to the tag compiler.&nbsp;</div><div><br></div><div>Doing it in the script compiler would be a bonus, but it would not solve the issue Henry was hitting. &nbsp;The tag compiler currently requires the super model to exist. &nbsp;<br><br>On Feb 11, 2009, at 17:40, Donald Anderson &lt;<a href="mailto:dda@ddanderson.com">dda@ddanderson.com</a>> wrote:<br><br></div><div></div><blockquote type="cite"><div>Are you suggesting we handle this in the tag compiler? &nbsp;Are there advantages to that?<div>Might be useful to have the capability in lzs code too.</div><div><br></div><div>- Don</div><div><br><div><div>On Feb 11, 2009, at 5:29 PM, P T Withington wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>This should be fairly easy. We already allow forward references to classes when instantiating them. It would just mean delaying completing the model until you need it, rather than at the time you parse it.<br><br>On Feb 11, 2009, at 16:22, Henry Minsky &lt;<a href="mailto:henry.minsky@gmail.com"><a href="mailto:henry.minsky@gmail.com">henry.minsky@gmail.com</a></a>> wrote:<br><br><blockquote type="cite">Currently the way the LZX compiler works, this code gives an error<br></blockquote><blockquote type="cite">"undefined superclass foo for class bar"<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">&lt;class name="bar" extends="foo"/><br></blockquote><blockquote type="cite">&lt;class name="foo"/><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">because the compiler parses classes internally in the lexical order<br></blockquote><blockquote type="cite">they occur in the source, and foo is not defined<br></blockquote><blockquote type="cite">yet when it tries to compile bar.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">However, we could make the compiler do a pass that stores the class<br></blockquote><blockquote type="cite">declarations and parses them on demand<br></blockquote><blockquote type="cite">so that the order you declare them lexically doesn't matter.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I guess we've gotten this far without the compiler doing this for you,<br></blockquote><blockquote type="cite">but I'm wondering if it would<br></blockquote><blockquote type="cite">be a useful thing to do, considering that other object oriented<br></blockquote><blockquote type="cite">languages generally seem to allow<br></blockquote><blockquote type="cite">it.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">-- <br></blockquote><blockquote type="cite">Henry Minsky<br></blockquote><blockquote type="cite">Software Architect<br></blockquote><blockquote type="cite"><a href="mailto:hminsky@laszlosystems.com"><a href="mailto:hminsky@laszlosystems.com">hminsky@laszlosystems.com</a></a><br></blockquote></div></blockquote></div><br><div> <span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><br class="Apple-interchange-newline">--</div><div><br>Don Anderson<br>Java/C/C++, Berkeley DB, systems consultant<br><br>voice: 617-306-2057<br>email:&nbsp;<a href="mailto:dda@ddanderson.com"><a href="mailto:dda@ddanderson.com">dda@ddanderson.com</a></a><br>www:&nbsp;<a href="http://www.ddanderson.com/"><a href="http://www.ddanderson.com">http://www.ddanderson.com</a></a><br></div></div></span></span><br class="Apple-interchange-newline"></div></span></div></span><br class="Apple-interchange-newline"></div></span><br class="Apple-interchange-newline"></div></span><br class="Apple-interchange-newline"> </div><br></div></div></blockquote></body></html>