5 ms·
The Programming Languages Zoo
- 0xDEEPFAC 5y agoCould Ada++ be part of the Zoo? xD
- Jtsummers 5y agoIt's not a miniature language, nor is it a real language.
- 0xDEEPFAC 5y agoSounds like a pedantic distinction without a difference ; )
- Jtsummers 5y agoIs it pedantic to point out that Ada++ is inconsistent with the objective of the site: > The Programming Languages Zoo is a collection of miniature programming languages which demonstrates various concepts and techniques used in programming language design and implementation. It is a good starting point for those who would like to implement their own programming language, or just learn how it is done. [emphasis added] And I know you've posted about Ada++ a few times (I thought I recognized your name, you were the submitter the day after April Fool's Day), but Ada++ is still not a real language. At best it's a cosmetic (and poorly done) transformation of Ada itself. I mean, this is a code sample from the site: case Variable: when 0 => Put_Line ("Zero"); when 1 .. 9 => Put_Line ("Positive Digit"); when 10 | 12 | 14 | 16 | 18 => Put_Line ("Even Number between 10 and 18"); when others => Put_Line ("Something else"); } Note the weird mismatch of the : as the starting delimiter for the block and } for the closing delimiter. Because literally `is` becomes `:` and `end` becomes `}`, and `begin` becomes `{`. Since `case` statements in Ada don't use `begin` but do use `is` you end up with this gross translation.
- qsort 5y agoSome of them also have compilers to a simplified machine object code. This is seriously amazing. I doubt I'll get anything else done for the rest of the day :D
- Jtsummers 5y agoThis is cool, and amusingly I wrote a simple calculator over the weekend (and will be adding variables this week when I get back to it) for a demo for work. minikanren or microkanren would be a good addition to this. There's already miniprolog so there's some overlap, but it's a well-defined language that's about the same size as some of these.
- slaymaker1907 5y agoI think there is still value in minikanren since it uses a different evaluation strategy than Prolog. While Prolog just has to support backtracking when things fail, minikanren requires much more interleaving of code paths. In terms of implementation, you can probably implement backtracking good enough for Prolog via backtracking, but you really need immutable maps for minikanren due to the interleaving. On the prolog side of things, prolog implementations typically care a lot more about being able to dynamically interact with the database including adding/retracing goals. Finally, minikanren tends to play nicer when combined with another language compared to prolog so it might be interesting to do include have it embedded in another language.
- whitten 5y agoI'm not expecting anyone to actually already have this done, but I would like to suggest that with the toy languages that a walk through of how to set up a language server protocol for the language would be rather helpful, and educational. This page claims to be a good starting point https://microsoft.github.io/language-server-protocol/ https://microsoft.github.io/language-server-protocol/
- franga2000 5y agoThe primary (?) author of this site (Andrej Bauer) is a professor at the University of Ljubljana. I'm currently in his Principles of Programming Languages course and I have to say, it is the one and only "theoretical" CS subject that I've really enjoyed! Old recordings of his other classes are also the only thing that helped me actually understand proofs of program correctness last semester. Seriously, I went through all our lectures and basic materials twice and still didn't get it. Then someone sent me one of his recordings and in 30 minutes, it all just clicked for me. Ended up getting 100% on that part of the exam, where before I wasn't sure I'd even pass.
- omniscient_oce 5y agoWhich video was it?
- franga2000 5y agoISRM-PPJ-2020-03-04 https://vimeo.com/396885838 https://vimeo.com/396885838
- hardwaregeek 5y agoMini languages are so fun! I wrote an absurd language for my GraalVM internship application that’s implemented in Ruby, Java and JavaScript. Quite absurd but a lot of fun: https://github.com/nicholaslyang/for-the-graal https://github.com/nicholaslyang/for-the-graal
- dang 5y agoSome past threads: The Programming Languages Zoo - https://news.ycombinator.com/item?id=18638290 https://news.ycombinator.com/item?id=18638290 - Dec 2018 (13 comments) The new and improved Programming Languages Zoo - https://news.ycombinator.com/item?id=12441903 https://news.ycombinator.com/item?id=12441903 - Sept 2016 (2 comments)