Generic discussion about OneLang. Please read the FAQ first! (https://github.com/koczkatamas/onelang/wiki/FAQ)
echo "that text";
Disclamer: I don't know Haxe well, so if you know it better and you could improve the contents of this page, please tell me by opening an issue (but first check if there is one already).
@mikicho mainly because I wanted to learn how to parse languages, generate syntax via templates, see the differences between languages first hand. Reading other's code is less fun for me than doing it actually from ground zero.
Other reasons: I wanted to be able convert from one language's syntax to other and AFAIK Haxe only accepts Haxe as input language, so simply it would not work. Also one of the goals of the project to be able to compile Onelang itself to every supported language, which would be near impossible with Haxe
One of the project where I thought One could come handy had to run in the browser, so I had to use a language which converts to JS.
[1, 2, 3].push(4);
in js gets converted to []int{1, 2, 3} = append([]int{1, 2, 3}, 4)
in go and new List<int> { 1, 2, 3 }.Add(4);
. while some funcs like Array.pop
are not supported. so i'm wondering are there any docs on the list of APIs supported by onelang? thanks.
hi @mgenware ! Sadly Onelang does not really support language stdlib methods yet (there are a few exceptions, as you mentioned). I should've emphasized this point in my communication, sorry if I was not clear enough about this. You can view the currently supported methods here: https://github.com/koczkatamas/onelang/blob/master/langs/StdLibs/stdlib.d.ts
Currently Onelang is a toolkit for converting syntax mostly. Although you can add any new methods even in the WebIDE, this is of course can be a lot of work. Here is the main issue about supporting libraries (not just syntax): koczkatamas/onelang#9