Comment by papercrane

1 year ago

Whitney is famous for writing code like this, it's been his coding style for decades.

For example, he wrote an early J interpreter this way in 1989. There's also a buddy allocator he wrote at Morgan Stanley that's only about 10 lines of C code.

https://code.jsoftware.com/wiki/Essays/Incunabulum

https://github.com/tavmem/buddy/blob/master/a/b.c

When writing code in this manner, lines of code is kind of a meaningless metric. You could put the entire Linux kernel in one very long line of C.

  • It was meant just as an indicator of the code density. The actual line lengths are ~80 chars.