Re: Language translation

Kaz Kylheku <kaz@kylheku.com>
Wed, 5 Mar 2014 16:08:11 +0000 (UTC)

          From comp.compilers

Related articles
Language translation awgold70@gmail.com (Anthony Williams) (2014-03-05)
Re: Language translation DrDiettrich1@aol.com (Hans-Peter Diettrich) (2014-03-05)
Re: Language translation kaz@kylheku.com (Kaz Kylheku) (2014-03-05)
Re: Language translation jkallup@web.de (Jens Kallup) (2014-03-06)
Re: Language translation norjaidi.tuah@ubd.edu.bn (Nor Jaidi Tuah) (2014-03-10)
Re: Language translation awgold70@gmail.com (Anthony Williams) (2014-03-10)
| List of all articles for this month |

From: Kaz Kylheku <kaz@kylheku.com>
Newsgroups: comp.compilers
Date: Wed, 5 Mar 2014 16:08:11 +0000 (UTC)
Organization: Aioe.org NNTP Server
References: 14-03-009
Keywords: translator, comment
Posted-Date: 06 Mar 2014 06:04:01 EST

On 2014-03-05, Anthony Williams <awgold70@gmail.com> wrote:
> Dear Group,
>
> I'm facing the problem to translate language A into language B. The
> problem is, that A is an object oriented language (it supports
> classes, attributes of classes ...). But B is much simpler. It hasn't
> support for classes. There is only variables, functions. And my
> Question: How Could I Implement Classes in B. ...


It may not be possible if language B doesn't have things like pointers,
aggregate types such as vectors, or function indirection.


This question is too vague in its current form, lacking a detailed
specification of A and B.


[Of course it's possible unless the language is weaker than Tiny
Basic. But it might be really ugly, e.g., parallel arrays to simulate
structures and glue functions that dispatch on an index parameter to
sort of fake function pointers. Like I said, it's tedious. -John]


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.