Re: True Name Spaces, when?
- From: "Rudy Velthuis [TeamB]" <newsgroups@xxxxxxxxxxxx>
- Date: Tue, 19 Feb 2008 12:32:47 +0100
L wrote:
The whole "single pass" phrase is kind of a misleading term..IMO.
IMO, during parsing there are several "inner sub passes" to make sure
syntax is right.. and things get fastforwarded/rewound while you are
analyzing stuff after or during the pass.. so it is not really a
single pass at all. It depends on how you visualize parsing, but I
don't see it as this one big pass that occurs.. rather I see a hole
bunch of mini passes, whether or not it included one big single pass
too, to make the whole thing work.
There may be fixups (or whatever you call them), but in fact, it is a
single pass, the compiler only reads forward, IOW, it doesn't have to
either do a rewind and read some passges twice, not does it have to do
a fast forward and read some parts in advance. Parts that are forward
declared must be fixed up (filled with life) as soon as their
definition is known: the compiler remembers the spots it has to fix up
in the parse tree and then fixes them as soon as it can (usually this
only means fixing up links - which were temporarily set to nil or some
such - with a link to real code). That does not mean that a part of the
source is parsed in advance or that some parts of the source must be
parsed twice. That is not necessary.
FWIW, the sources for the orginal Pascal compilers are freely available
(as Pascal source code). There you can see how this works. The current
compiler is more complex, but in fact still using the same techniques.
--
Rudy Velthuis [TeamB] http://www.teamb.com
"I'll moider da bum."
-- Heavyweight boxer Tony Galento, when asked what he thought of
William Shakespeare
.
- Follow-Ups:
- Re: True Name Spaces, when?
- From: L
- Re: True Name Spaces, when?
- From: L
- Re: True Name Spaces, when?
- References:
- True Name Spaces, when?
- From: Thomas Miller
- Re: True Name Spaces, when?
- From: Hans-Peter Diettrich
- Re: True Name Spaces, when?
- From: Alessandro Federici
- Re: True Name Spaces, when?
- From: Marc Rohloff [TeamB]
- Re: True Name Spaces, when?
- From: Henrick Hellström
- Re: True Name Spaces, when?
- From: Robert Giesecke
- Re: True Name Spaces, when?
- From: Hans-Peter Diettrich
- Re: True Name Spaces, when?
- From: L
- True Name Spaces, when?
- Prev by Date: Re: About Delphi Help System
- Next by Date: Re: True Name Spaces, when?
- Previous by thread: Re: True Name Spaces, when?
- Next by thread: Re: True Name Spaces, when?
- Index(es):
Relevant Pages
|