|
Project Information
Featured
Links
|
PurposeDil is a hand-crafted compiler implementation for the D programming language written in D 1.0 using the Tango standard library. The lexer and the parser are fully implemented. Semantic analysis is being worked on. The backend will most probably be LLVM.
Status- Dil shines at generating documentation from source files.
- Semantic analysis is very difficult. Only a little bit of it exists in Dil.
- Binaries cannot be generated yet.
News- 2011/09/21: First merge of a pull request made by klickverbot. Thanks for the contribution!
- 2011/07/14: The project is still still alive. Just busy with life in general, especially with running and weight training. ;-)
- 2010/12/25: Uploaded docs for Derelict2, DMDScript2, LanguageMachine, VisualD and Yage. PDFs and archives included.
- 2010/12/22: Generated docs for Tango 1.0.0, Phobos 1.066/2.051, MiniD2.0 and Dil.
Uploaded all files to a folder on Dropbox. More projects and PDF files to follow.
What Dil Can Do- Generate documentation from Ddoc comments.
In comparison to DMD, Dil has fewer bugs and also offers a few treats. It is possible to generate PDF documents from the HTML files using PrinceXML. See Kandil for more information. Example documentation of some projects (in one folder):
- Generate highlighted source files in HTML or XML.
Tokens only are highlighted by default, but the whole parse tree can be unparsed as well. The whitespace of the original source file is preserved. Any browser can display the HTML documents, but the XML documents can only be viewed in W3C-standards compatible browsers in combination with an XML formatting CSS document. Dil provides two ordinary CSS documents (for XML/HTML) which can be easily customized. Example: Dil's source code in XML or HTML (files are outdated).
- Produce module dependency graphs using the graphviz dot format.
For example, see the dot file of Dil: rendered in SVG, PNG (2.7MB) or GIF. Cyclic edges (import statements) and nodes (modules) are highlighted in red. The edges of public imports are bold.
- Output code statistics (lines of code, count syntax tree nodes and tokens, number of whitespace characters etc.) When Dil has advanced enough OO-metrics will be supported. Example: dstress (1.5MB text; totals are at the bottom)
- Dil is fully internationalized.
It can output compiler messages in English, German, Turkish and Finnish. You can determine which language to use with a setting in the configuration file.
HelpWriting a fully functional compiler is a huge undertaking and can therefore take months and years for a single person. Perhaps you would like to give a hand and speed up the development of this project. Here are some of the things you could do for Dil and the D community: - Document the inner workings of DMD's front-end, specifically semantic analysis (SA.) This would help me immensely to implement SA for Dil and be as close to the official D compiler as possible. Or you could:
- Lobby for better and clearer D language specifications.
- Learn git and start writing code for Dil. The code you write will be credited to you, even if I commit the patches (as git distinguishes between author and submitter of revisions.)
- Any kind of interesting feedback is always welcome.
Planned Features- Refactoring (renaming symbols, modules; changing the type of a symbol etc.)
- Coding rules enforcement.
- Code search.
- Code analysis (lint-like).
- Code formatting.
- Translate D code to other languages.
- Port D 1.0 code to D 2.0.
Meaning: The word 'dil' comes from the Turkish language and means among other things a) tongue or b) language. It is a very fitting name for this project because of its meaning and because it starts with the letter D and for the reason that the project owner has Turkish origins. ContactFeel free to join my IRC channel, #dil, which I've set up on freenode.net. You can also send me a plain e-Mail if you have questions regarding my project. LicenseSome people might not like the license under which Dil is currently being developed. In fact, it could be off-putting for some programmers who would like to contribute to it or make use of it as a client. However, please keep in mind that a lot of hours were spent in order to come up with a compiler that is well documented and has a solid design. It is not unlikely that the author will put the project under a less restrictive license one time or another. It could be LGPL3 or even BSD. It very much depends on how many cookies and apple pies somebody is willing to stuff the author with. :P DownloadThere are no downloadable binaries yet. Go to the Source page to find out how to get the code using Git. If you have DSSS you can use the fetch command, "dsss net fetch dil.zip", to get the latest revision of the source code. Statistics
|