digitalmars.D - 'Hello world' of a D parser
- B.G. (16/16) May 11 2005 I took a look at the source code of the dmd front-end and was unable to
- Joey Peters (4/19) May 11 2005 Ben Hinkle made a front end starters kit. I think if you search for it o...
- =?ISO-8859-1?Q?Val=E9ry?= (2/8) May 11 2005 Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/
- pragma (4/12) May 11 2005 Take it from me, it's a great starting point. I already have a renditio...
- Charlie (8/24) May 11 2005 Coolness, maybe it'll blossom into a XML -> MSIL :) ?
- B.G. (4/22) May 13 2005 Plain dmdfe still appears to be rather obscure, although it's very cool.
- pragma (9/28) May 13 2005 Sure! Check out "Dexter":
- B.G. (3/15) May 13 2005 Hey, this is AWESOME!
- Ben Hinkle (6/20) May 13 2005 no problem. It's 99% Walter's front end and I just added the stubs for t...
I took a look at the source code of the dmd front-end and was unable to find sort of an 'entry point' into it. The parse method somewhere expected a lot of 'prerequisites', so I just can't figure out where to start from. The readme file states that the code is not ready for compilation or something like that, and I wonder what would it take to make a hello-world program out of it. What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it. Any suggestions are likely to save me a lot of time spent on reverse-engineering and would be very much appreciated. Regards!
May 11 2005
Ben Hinkle made a front end starters kit. I think if you search for it on the announce group you'll find it somewhere. "B.G." <gbatyan gmx.net> schreef in bericht news:d5t1ip$10o1$1 digitaldaemon.com...I took a look at the source code of the dmd front-end and was unable to find sort of an 'entry point' into it. The parse method somewhere expected a lot of 'prerequisites', so I just can't figure out where to start from. The readme file states that the code is not ready for compilation or something like that, and I wonder what would it take to make a hello-world program out of it. What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it. Any suggestions are likely to save me a lot of time spent on reverse-engineering and would be very much appreciated. Regards!
May 11 2005
B.G. a écrit :What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it.Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/
May 11 2005
In article <d5t312$11q1$1 digitaldaemon.com>, =?ISO-8859-1?Q?Val=E9ry?= says...B.G. a écrit :Take it from me, it's a great starting point. I already have a rendition based on this that emits XML files (suitable for documentation) based on D code. - EricAnderton at yahooWhat I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it.Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/
May 11 2005
Take it from me, it's a great starting point.Seconded, its very nice.I already have a rendition based on this that emits XML filesCoolness, maybe it'll blossom into a XML -> MSIL :) ? Charlie "pragma" <pragma_member pathlink.com> wrote in message news:d5tba3$182o$1 digitaldaemon.com...In article <d5t312$11q1$1 digitaldaemon.com>, =?ISO-8859-1?Q?Val=E9ry?=says...givenB.G. a écrit :What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing abasedTake it from me, it's a great starting point. I already have a renditionD file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it.Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/on this that emits XML files (suitable for documentation) based on D code. - EricAnderton at yahoo
May 11 2005
pragma wrote:In article <d5t312$11q1$1 digitaldaemon.com>, =?ISO-8859-1?Q?Val=E9ry?= says...Plain dmdfe still appears to be rather obscure, although it's very cool. Any examples would be appreciated a lot, can I take a look at your code? Thanks!B.G. a écrit :Take it from me, it's a great starting point. I already have a rendition based on this that emits XML files (suitable for documentation) based on D code.What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it.Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/- EricAnderton at yahoo
May 13 2005
In article <d62tvl$2nio$2 digitaldaemon.com>, B.G. says...pragma wrote:Sure! Check out "Dexter": http://svn.dsource.org/projects/dsp/trunk/dexter/ (sorry, no zip archive right now. Examples are the .d and .xml files in the root directory) Most of the work is in /stubs. I *did* have to do some small modifications to bits and pieces of the codebase (most of which are in lexer.c and parser.c). A diff of this and the original dmdfe should tell all. - EricAnderton at yahooIn article <d5t312$11q1$1 digitaldaemon.com>, =?ISO-8859-1?Q?Val=E9ry?= says...Plain dmdfe still appears to be rather obscure, although it's very cool. Any examples would be appreciated a lot, can I take a look at your code?B.G. a écrit :Take it from me, it's a great starting point. I already have a rendition based on this that emits XML files (suitable for documentation) based on D code.What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it.Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/
May 13 2005
Valéry wrote:B.G. a écrit :Hey, this is AWESOME! Thank you very much...What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it.Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/
May 13 2005
"B.G." <gbatyan gmx.net> wrote in message news:d62tr2$2nio$1 digitaldaemon.com...Valéry wrote:no problem. It's 99% Walter's front end and I just added the stubs for the backend and removed some of the front-end code having to do with data segment layouts (so I'm actually kindof curious what capabilities that throws out...).B.G. a écrit :Hey, this is AWESOME! Thank you very much...What I mean here is the minimal compilable program based on the soruce code of the DMD front end (off course as non-intrusive as possible in respect to the original DMD code). All it needs to do is parsing a given D file, check it for syntactic and semantic errors and either get the errors in a structured form for custom processing, or get the parsed tree and any information acquired for further processing. That's it.Have a look at Ben's DMDFE : http://home.comcast.net/~benhinkle/dmdfe/
May 13 2005