DirectorySoftwareBlog Details for "writing a compiler"

writing a compiler

writing a compiler
A log of my efforts to learn how compilers work by tring to write my own compiler.

Articles

It's hard to begin
2007-04-12 23:15:00
I haven't done much about my compiler project last week.I've been doing lot's of reading digging through old topics on comp.compilers newsgroup. On that page I found a link to a textbook on compilers available on line for free. So now I'm reading Basics of Compiler Design by Torben Mogensen. But having lot's of work at my daily job I now reading as much as I wish to.I've already made some decisions about my project. I've decided to write a pascal compiler and I'm going to implement it in plain old C. I haven't yet decided about my output language. I'm considering C or assembler.From reading Torben's book and comp.compilers I already know how a complier should work.At the begging compiler has to do lexing, which is basically reading character data and converting it into lexical tokens. This mean that a lexer will convert: result := 2; intoIDENTIFIER "result"BECAMESNUMBER "2"SEMICOLONThere are some lexer generators which will generate source code of a lexer form set of...
More About: Hard
List of thing to begin with.
2007-04-06 18:08:00
Here is a list of thing that I need to do before I can start writing any code.Getting materials on compiler writing.I'm going to look all over the Internet. I'm also considering buying some books, like the "red dragon book".Chose a language I'm going to compile.This is very important decision to make. Choosing to complex language I'll probably end up spending most of my time getting to know this language instead of writing a compiler. This means that I won't chose any object oriented language. Also if the language has very simple syntax (like assembly) I might not learn that much (this statement might be wrong).I'm looking for a simple functional language that allows doing simple operations like + - * /, has few control statements (if, while and for loop). If you have written a simple compiler let me know what language did it compile.I might also end up creating my own language or implementing a small subset of some common language.Choosing in what language I'll write.Right n...
More About: With , List , Thing
What is it going to be about?
2007-04-06 17:46:00
Reading Joel On Software Archive I ran into an article describing the development of ASP to PHP compiler. This article has inspired me to try to write my own compiler. Many developers consider it is "a must do task" for good programmer to develop an operating system and a compiler.At the moment of writing this I have experience in programming and good knowledge of many programming languages including low level languages like ammebly and high level object orinted languages like C++, Java or C# but I have no idea how compilers work.I have some ideas how it can be done, but i haven read ant books or articles about it, so I know that my ideas might be wrong.
More About: What , Hat , About , Going , Goin
40987 blogs in the directory.
Statistics resets every week.


Contact | About
© Blog Toplist 2008 - SEO by FeWorks
eXTReMe Tracker