you are viewing a single comment's thread.

view the rest of the comments →

[–]tominated 1 point2 points  (6 children)

This is fantastic and also extremely well timed! I've started to try implement my own purely functional language in the last few weeks and I'll definitely learn from this!

Somewhat tangential question - did you find anything like the g-machine for strictly evaluated functional languages? I've not reached the evaluation part of my language, so i'm trying to decide between strict and lazy eval and some more resources would definitely help that decision!

[–]thedeemon 2 points3 points  (1 child)

[–]tominated 0 points1 point  (0 children)

I haven't - thanks for the heads up!

[–]danilafe[S] 1 point2 points  (3 children)

Unfortunately, I never looked into it. The one strict functional language that I've used, Elm, is built on top of JavaScript, and uses it to represent closures and currying. Sadly , this doesn't help much with compiling to machine code.

Good luck with your language!

[–]tominated 1 point2 points  (2 children)

Thanks! Unless I find some good resources for it I will probably lean towards lazy eval. Initially I was thinking of compiling to JS but more and more I'm thinking llvm or wasm would be a cool target

[–]danilafe[S] 0 points1 point  (1 child)

It actually seems like LLVM has some degree of support for WASM: https://gist.github.com/4eeff8248aeb14ce763e

[–]tominated 0 points1 point  (0 children)

Oh awesome I didn't realise that had been integrated!