Re: FWD:Re: refactoring

Stefan Seefeld <[email protected]>
Newsgroups gmane.comp.documentation.synopsis
Message-ID <[email protected]>
Joel de Guzman wrote:

>>> Types are values in the POV of the compile time interpreter.
>>
>>
>>
>> Also in the POV of a compiler ;-)
> 
> 
> It is a fact that in C++, the line between the parser (front end)
> and the compiler (backend) blurs. You need some smarts of the compiler
> to reliably parse C++. The sizeof comes to mind, for example.
> By "compiler", I mean the backend code generator.

I don't think the backend really comes into play. All that is needed
is a set of rules that lets the analyzer make statements about object size,
alignment, and so forth or anything else that may affect the type system.
This doesn't involve anything backend- (i.e. architecture-) specific.

> Yes. If the formalized compile time interpreter is simple enough
> like the language Scheme, we can easily have a compile time
> meta-compiler-compiler that compiles directly to compiler object
> code. Then, TMP infrastructure libraries such as MPL can start
> doing meta-meta-programming :-)

What I have in mind with synopsis (to keep this discussion on track ;-)
is to expose the various aspects both of the intermediate representations
as well as the analyzers to python, and then allow users to script.
This allows them both to trace the processing as well as to do something
completely outside the 'std C++' domain.
In fact, that is where the code I'm currently working with originated
from: OpenC++ (http://www.csg.is.titech.ac.jp/~chiba/openc++.html).

Regards,
		Stefan
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.