www.digitalmars.com Home | Search | C & C++ | D | DMDScript | News Groups | index | prev | next
Archives

D Programming
D
D.gnu
digitalmars.D
digitalmars.D.bugs
digitalmars.D.dtl
digitalmars.D.ide
digitalmars.D.dwt
digitalmars.D.announce
digitalmars.D.learn
digitalmars.D.debugger

C/C++ Programming
c++
c++.announce
c++.atl
c++.beta
c++.chat
c++.command-line
c++.dos
c++.dos.16-bits
c++.dos.32-bits
c++.idde
c++.mfc
c++.rtl
c++.stl
c++.stl.hp
c++.stl.port
c++.stl.sgi
c++.stlsoft
c++.windows
c++.windows.16-bits
c++.windows.32-bits
c++.wxwindows

digitalmars.empire
digitalmars.DMDScript
electronics




D.gnu - Implementation Documentation

↑ ↓ ← "Hans W. Uhlig" <huhlig gmail.com> writes:
Just out of curiosity, is there a rules document on the syntax, grammar 
and D language, I have been looking over the site to begin working on a 
lexer library but cant find it.
Apr 20 2008
→ BCS <ao pathlink.com> writes:
Reply to Hans,

 Just out of curiosity, is there a rules document on the syntax,
 grammar and D language, I have been looking over the site to begin
 working on a lexer library but cant find it.
 

the rule are scattered through the documentation. I have a sed script that will extract them (I think it will work on the official version but I have only done it with a patched version that has been merged into the trunk). By the way, there a several errors in the documentation. I'm (as time permits) working on fixing them but it's kind of low on my current priority list. the sed script: http://www.dsource.org/projects/scrapple/browser/trunk/dparser/gram.sed the bash script used to run it: http://www.dsource.org/projects/scrapple/browser/trunk/dparser/cut_gram2 (you will need to modify it to fit your system)
Apr 20 2008
→ Bill Baxter <dnewsgroup billbaxter.com> writes:
Hans W. Uhlig wrote:
 Just out of curiosity, is there a rules document on the syntax, grammar 
 and D language, I have been looking over the site to begin working on a 
 lexer library but cant find it.

Is there any reason you can't use one of the existing D lexers out there? --bb
Apr 20 2008