← Back to context

Comment by skissane

2 days ago

The core idea-a language with a built-in persistent key-value store-is actually pretty cool.

The classic implementation is filled with horrible warts, although arguably many of them were helpful in squeezing a production multiuser system into the tiny resource constraints of the original 1960s implementation platform (18-bit PDP-7, same machine as Unix was birthed on, although Unix soon moved to the 16-bit PDP-11, which was in practice more spacious)

Modern implementations make many of those warts optional, although they still support them for backward compatibility

The biggest problem with the language in practice is that many major code bases (e.g. VistA) are still predominantly written in the legacy extremely terse coding style rather than a more modern readable style. I do wonder why there isn’t more effort put into migrating to a more modern style, especially since with the kinds of tools we have nowadays that migration could be (at least partially) automated.

The VA still requires "routines" to be < 20000 characters. So programming with single letter commands will always be ingrained in M code. Besides its a lot less typing :) The biggest problem I have with the ecosystem is the $P (PIECE) command (splits ^-delimited strings) bled into the GUI codebase so everywhere the devs wrote code like if Piece(3)=1 making it impossible to reason about.

FoxPro(dBase family) was a much better take on the idea.

I also dream of something modern like this (https://tablam.org) but is certainly a significant undertaking. Accept partners!

  • > FoxPro(dBase family) was a much better take on the idea

    xBase is arguably a very different idea - it is based on flat-file/key-indexed databases, akin to VSAM on IBM mainframes, but wrapped in a 4GL. The experience of xBase is very similar to many mainframe 4GLs, what made it distinctive was providing that experience on low-end platforms (it started out on 8-bit CP/M systems, but it was on 16-bit DOS that it really took off)

    By contrast, MUMPS has multidimensional associative arrays as a basic data type, and the difference between temporary (in-memory) and persistent (on-disk) arrays is simply whether the variable name is prefixed by a caret. Perl’s tied arrays are close, but tied arrays are a rather peripheral feature of Perl (many Perl code bases never use them), but a central feature of MUMPS