Best way to implement metalanguage compiled before PHP

I am working on the / kitchensink specification for a metalanguage that can compile to PHP for some time. Now I want to start building a thing. Before I implemented tiny DSL using PHP_Lexergenerator and PHP_Parsergenerator, they worked very well, but I had never built anything of this scale before. I would appreciate any feedback / suggestions / impressions that you may have very important.

I inserted the spec in http://pastebin.com/613mFGsB .

+4
source share
3 answers

Do not let other people's similar projects stop you from doing this. No matter how far you handle this, what you really get from this project is a further understanding of coding and parsing. You cannot get this knowledge in depth if you simply join an existing project.

I would also like to point out that things like Linux, Ubuntu, etc., would never have existed if their original manufacturers had just jumped on a boat of another such project. Do not be afraid to do things yourself, sometimes greatness comes from this.

+5
source

Haxe is a language that implements PHP as a compilation target. It is like what you are trying to achieve. This is OSS so you can see how they do it.

+4
source

pihipi was an interesting example of this, but now I killed him. So check out Haxe: Haxe is a language that implements PHP as a compilation target. It is like what you are trying to achieve. This is OSS so you can see how they do it.

+2
source

Source: https://habr.com/ru/post/1303114/


All Articles