POV-Ray : Newsgroups : povray.general : Who Not Make Naming Conflicts Disappear? : Re: Who Not Make Naming Conflicts Disappear? Server Time
31 Jul 2024 16:21:15 EDT (-0400)
  Re: Who Not Make Naming Conflicts Disappear?  
From: Randall Sawyer
Date: 6 Dec 2006 20:25:00
Message: <web.45776c12315c6ef0e81faf070@news.povray.org>
Sabrina, I just realized that I failed to respond to one of your concerns in
my last post.

Sabrina Kilian wrote:
> Making the user
> include each subfile just to have access to it seems like a good way to
> increase parse time and annoy the user.

I have given this some consideration.

First of all, will it actually be a common occurence that a POV-Ray author
will want to include both an include file and one-or-more of the include
files which that include file also includes?  It's question worth
considering, especially if the library is made up of files with fairly
discrete contents.

For arguments sake, I'll assume that this is indeed going to happen
frequently.  One idea I have is that each include file would be parsed to
the point of containing raw-code-tokens only before it is actually included
into the next file up the chain.

Otherwise, perhaps there is a way to modify the aliasing algorithm to allow
for 'membrane namespaces' to overlap, thus demanding that each include file
in the tree be accessed only once.  Of course, if an author includes a file
which is also included by another include file, then its namespace will
have to be restored before the parser includes it in the root file.

-Randall


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.