Related articles |
---|
Building a translator. Want to know if this is feasible... socrates171@yahoo.com (socrates) (2002-11-06) |
RE: Building a translator. Want to know if this is feasible... onderkarpat@yahoo.com (Onder Karpat) (2002-11-07) |
From: | "Onder Karpat" <onderkarpat@yahoo.com> |
Newsgroups: | comp.compilers |
Date: | 7 Nov 2002 00:49:07 -0500 |
Organization: | Compilers Central |
References: | 02-11-013 |
Keywords: | translator |
Posted-Date: | 07 Nov 2002 00:49:07 EST |
Hi,
First you had better be sure about if Java or target language is
sufficient to represent all kinds of original language
constructs/outputs.
If you sure about it. Then check if the original language grammar is
available. Existence of grammar will ease your task.
If original language is having a preprocessor then target language had
better have too.
If you know the expected results of available programs for original
language then I think there is a chance that you can get a good
translator.
I would start by first developing a preprocessor / lexer / parser for
original language which accept all the original language source
programs. Then you can build a parse tree and generate target language
statements/constructs.
Studying compiler front-end related documents/books should be
sufficient for this task. It is pretty similar to any compiler
front-end.
Oender
Return to the
comp.compilers page.
Search the
comp.compilers archives again.