5 ms·
Make Your Own Programming Language (2015)
- dkarapetyan 10y agoReally funny how the inspiration is python and haskell but there are 0 features from haskell.
- Pirate-of-SV 10y agoType declarations are similar to Haskell's. Haskell is also whitespace dependent.
- dkarapetyan 10y agoThat's not what makes Haskell what it is. It's not the type declaration syntax or the white space awareness. In fact those things are so superficial that they might as well not be mentioned.
- lgas 10y agoWhile this is true, the post lists 9 specific examples of features directly below that quote, of which 5 are found in haskell. He never said he tried to capture the essence of Haskell, simply that features in his language were inspired (in part) by Haskell.
- marianoguerra 10y agoin case you are interested I made a step by step repo creating a programming language for the erlang vm here: https://github.com/marianoguerra/otl/commits/master https://github.com/marianoguerra/otl/commits/master follow each commit in reverse order to get the step by step creation. it was part of 2 talks I gave but I think you can follow it just by reading the commits. here are the slides: http://marianoguerra.org/talks/elixir-karlsruhe-meetup/ http://marianoguerra.org/talks/elixir-karlsruhe-meetup/
- cothalesr 10y agoHere's a relevant book in the works that everyone should keep their eye on. http://beautifulracket.com/ http://beautifulracket.com/ It'll be interesting to compare how "making your own language" is achieved in both guides. Although, the racket situation may be super different, the basic steps seem to be similar.
- sndean 10y agoThis reminded me of something that helped me learn C a while ago: http://www.buildyourownlisp.com/contents http://www.buildyourownlisp.com/contents Seems like even attempting to make your own language will teach you a lot.
- jasonjei 10y agoThis brings back so many memories from my compilers class back in school. Lexers to generate tokens, tokens to parsed from grammar, then translated to intermediate code... And those pesky ASTs...
- throwaway2016a 10y agoI find it interesting there is no mention of Backus-Naur Form (BNF) in here. It's the formal language to describe the syntax of programming languages. Nor of there a mention of Flex/Bison or Lex/Yacc. I know those tools aren't cool... being decades old and all. But they are very battle hardened and make development much faster. I don't know the background of the author or if they have a computer science degree. And I am most definitely not one to do something one way just because that is the way it has always been done. But articles like this seem to fly in the face of decades of computer science advancement. As a fun project where you learn a lot, great, I just hope someone doesn't try to use this to make anything that isn't a toy language.