rainy
April 26, 2022, 2:33am
1
I’m trying to use haxe to compile to Ocaml, and then from Ocaml to native code. At present, I have implemented some compilation contents.
Github:GitHub - rainyt/ocaml-haxe: 使用Haxe编写OCaml代码
rainy
April 26, 2022, 2:35am
2
At the same time, I’m simulating some sys API, such as file. Of course, the project is only for learning to use. I also need to learn the content of Ocaml.
rainy
April 27, 2022, 6:32am
3
Today, I imitated the file system API and solved some processing of some type returns.
rainy
April 29, 2022, 1:17am
4
I’m trying to translate the construction of new class() into Ocaml; Here I still use method access.
Later I’ll try how to access methods in objects.
Simn
(Simon Krajewski)
April 30, 2022, 9:48am
5
Did you consider using OCaml classes? I don’t know how well they map to Haxe, but it would save you the trouble of reimplementing OO-semantics.
rainy
May 1, 2022, 7:16am
7
At present, I temporarily use the access method to implement object-oriented content. The variable initialization value is now implemented.
And the method access of object is realized,
var process2 = new Process("haxelib -help");
var data2 = process2.readAllString(">>>><<<");
trace(process2.getProcess2().name);