I must admit I am very old fashioned, but if you go for the
learning
experience, I'd recommend designing a simple grammar and
build the parser as
a recursive descend and the lexer as a state machine.
It'll take a fair amount of hand work, but the result is
much more
debug-able than a table driven implementation.
-- Henkk
-----Oorspronkelijk bericht-----
Van: Compiler Developers for .NET
[mailto OTNET-LA
NGUAGE-DEVS DISCUSS.MICROSOFT.COM] Namens Zeddy Iskandar
Gunawan
Verzonden: Tuesday, January 03, 2006 7:28 AM
Aan: DOTNET-LANGUAGE-DEVS DISCUSS.MICROSOFT.COM
Onderwerp: Implementing a simple OOP compiler using AST
Hi there,
Joined this list after watching Pobar & Duffy's PDC
compiler-in-1-hr demo.
I've read somewhere that AST is useful when implementing a
compiler for an
OOP language.
Can you gurus give me some pointers on this/how tos/where to
look/etc?
Kind regards,
Zeddy.
|