[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Tinycc-devel] Extend tcc to use viable.
From: |
Yair Lenga |
Subject: |
[Tinycc-devel] Extend tcc to use viable. |
Date: |
Thu, 24 Feb 2022 13:38:41 -0500 |
Hi,
I am working on a project to convert a proprietary DSL language into standard
one. The proprietary language is executed by interpreter engine from intermedia
representation. The challenge is maintaining the language and the runtime.
I am exploring an option to use compile-on-the-fly approach by translating the
DSL to c, compile/execute in memory. Language is Fortran/c style, and is “safe”
(no pointers, atomic strings, and bound-checked arrays) - most statements can
be converted to c.
One challenge is methods. Language allow simple OO calls obj->method. The
challenge is how to tell obj->prop (value), vs obj->method (function call). The
translator can do it, if it will build parse tree, symbol tables. This is much
more work than a statement by statement translator.
I was hoping it will be possible to make a small change to tcc, introduce a new
operator (e.g. obj@func), which will be equivalent to obj->method() (function
call) or obj->prop (member value), based on the type of the member (function
pointers). Can anyone comment on readability of making such a change to tcc ?
Thanks, yair
Sent from my iPad
- [Tinycc-devel] Extend tcc to use viable.,
Yair Lenga <=
- Re: [Tinycc-devel] Extend tcc to use viable., Christian Jullien, 2022/02/25
- [Tinycc-devel] Re : Re: Extend tcc to use viable., david . koch, 2022/02/25
- Re: [Tinycc-devel] Re : Re: Extend tcc to use viable., Steffen Nurpmeso, 2022/02/25
- [Tinycc-devel] Re : Re: Re : Re: Extend tcc to use viable., david . koch, 2022/02/25
- Re: [Tinycc-devel] Re : Re: Re : Re: Extend tcc to use viable., Domingo Alvarez Duarte, 2022/02/25
- [Tinycc-devel] Re : Re: Re : Re: Re : Re: Extend tcc to use viable., david . koch, 2022/02/25
- Re: [Tinycc-devel] Re : Re: Re : Re: Extend tcc to use viable., Steffen Nurpmeso, 2022/02/25