Making a new programming language...,
Moderators - Reputation: 979
Posted 21 January 2002 - 12:10 AM
There are several good books on the subject (Modern Compiler Implementation in C/Java/ML is the textbook we used).
Basically, you start off with a "Lexer" - something that converts a text-file into something more computer-readable. Then, a "Parser" converts the output of a lexer to an abstract syntax tree (have I lost you yet?). Then, the compiler back-end converts the abstract syntax tree into a stream of assembler commands, using various techniques.
If you want to learn more about it, I suggest you try to find a book about it, or search the net for a compiler tutorial, I think there are a few around.
Edited by - MadKeithV on January 21, 2002 7:11:11 AM