Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Cranks don't really put their money where there mouth is. If you haven't seen it yet, I'm sure you'll enjoy looking at the STEPS project: http://www.vpri.org/html/writings.php

In summary, the goal is a user-facing system in 25k SLOC, from kernel to GUI apps, including all the code for compilers for the custom languages they made. They call the languages "runnable maths", or "active maths", where they think of a minimal notation to specify how a system should behave, and then implement a compiler to run that notation as code. They manage this through a compiler-writing language, ometa.

For example, to implement TCP/IP, they parse the ASCII tables from the RFCs as code. Seriously, they just take it as is, and have a compiler to run it as code. The implementation is supposed to be around 200 LOC (includes the code written in Ometa for their compiler).

There's also a graphic subsystem, apparently with all the functionality of Cairo (which is 20k LOC) in about 800 LOC.

Crucially, all this code is supposed to be very readable. Not line noise like APL. The expressiveness comes from having custom languages.



There was a previous discussion of the 200 line TCP/IP stack on hacker news: https://news.ycombinator.com/item?id=846028

I believe most of the code is visible in the linked article. The packet diagrams were redone but are very nearly identical to the RFCs, just some minor formatting tweaks. They are very readable.

The compiler (in OMeta) is a very BNF like grammar.

The readability is striking. The first time I heard of it, I was expecting it to be extra dense and hard to parse. It turns out they have entire lines of just separators counting against their limit, which seems useless until you realize one of the main goals is readability.

Incredible work, I'm looking forward to the end result.


This style seems amazing, but I haven't seen any tutorials for people interested in learning how to do this themselves.. do you know of any such resources?


They are doing the real deal thing - for each problem, designing a language in which to express the solution, and then writing the solution. Part of the point is that the building such solutions isn't really teachable in the context of a tutorial. If a tutorial can teach it, then it's probably a pretty shallow skill, and shallow skills should get designed away into a solution-oriented programming language, and any tutorials for THAT language, etc etc...

The language they use to do that (O-Meta) is then a language-defining language, and designing THAT means balancing on a level of abstractions that is at least three levels deep, and each of those abstraction levels is hard and necessary. They achieve great simplicity by thinking damn hard.

On the other hand, the mailing list (as noted by the other respondent) is a pretty interesting place with few flamewars.


I think this tutorial does a pretty good job: http://news.ycombinator.com/item?id=4230995


This is exactly what I was looking for. Thanks.


Thank you - the light just went on for me! Is this what is meant by Domain Specific Languages (DSL's) ?


Ask around on their mailing list they are quite helpful. I also asked a similar question from the viewpoint of the TECS book: http://www.mail-archive.com/fonc@vpri.org/msg01614.html


STEPS is cool, but IMO he should badmouth the entire industry after he ships it.


That would be nice, but I think STEPS is a research project that looks into how things can be done differently. It would be nice if this particular implementation would result in a shippable product. But I doubt if that is their primary goal.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: