<div dir="auto">I was unable to focus on your pseudo code, Andreas, so I post this follow-up.</div><div dir="auto"><br></div><div dir="auto">Here’s some specific circular logic which should not be allowed, editing Andreas’ example. Note that the extern PROTOs are at the “top” of the files, so any serial loading would bounce back and forth between files. Loading in parallel probably wouldn’t work either.</div><div dir="auto"><br></div><div dir="auto">The only way to handle this I know of is to avoid ExternProto’s during parsing if you’ve already seen them.</div><div dir="auto"><br></div><div dir="auto">I don’t know if the spec already handles this or not. I agree that PROTOs or extern PROTOs should not be able to reference each other circularly.</div><div dir="auto"><br></div><div dir="auto">I do know there is “registration” of PROTOs, but I don’t know how it’s related to scoping/nesting of PROTOs.</div><div dir="auto"><br></div><div dir="auto">I will try to understand the pseudo code again. If only we could animate X3D processing via email!</div><div dir="auto"><br></div><div dir="auto">John</div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Apr 29, 2022 at 9:52 AM Andreas Plesch <<a href="mailto:andreasplesch@gmail.com">andreasplesch@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;padding-left:1ex;border-left-color:rgb(204,204,204)" dir="auto">Hi John,<br>
<br>
Here is a draft of an example of a circular definition:<br>
<br>
file A.x3d:<br>
<br>
ExternProtoDeclare name='B' url=' "B.x3d" '<br>
<br>
file B.x3d:<br>
<br>
ExternProtoDeclare name='A' url=' "A.x3d" '<br><br>
</blockquote></div></div>