I enjoyed my university learning of SML a lot less than I think I should have done. Coming back to it later I was really impressed.
Before university I'd programmed (primarily in BASIC) for many years, so imperative programming just made sense to me. Functional programming seemed alien and the amazing type system of ML-like languages just seemed to get in my way.
What I was missing was the context to understand why it was good. And, to be honest, some compelling examples - we almost completely glossed over IO and system interfaces and the gyrations required to do things like efficient iteration just seemed a bit pointless.
It was good computer science but I found it to be very unsatisfying engineering as I couldn't see how to build something useful. This may be my fault for not doing an engineering degree ;-)
Once I understood more of how these systems are built at lower levels I was much better equipped to be impressed by how much of that was hidden from view!
Same thing here (but with Ocaml). You come into this intro course as someone who can already program and it feels like such a weird take that they deliberately steer you away from playing around and building something cool. IO being important is a hill I'm willing to die on, at least for certain kinds of learners.
Steering me away from bad habits or towards more computer science did make sense - but, yes, actively discouraging me from building things I found cool didn't help my motivation.
It didn't deter everybody, though - my friend went full speed ahead and implemented a graphical MacOS application using SML that forwarded e-mails over SMS so he could read them on his phone.
The bricklayer IDE and bricklayer-lite are SML IDEs FWIU [1]. Could Millet and/or three Millet VSCode extension and/or the SML/NJ Jupyter kernel [2] be useful for creating executable books [3][4] for learning?
> Bricklayer libraries provide support for creating 2D and 3D block-based artifacts. Problem-solving and math are used to exercise creative and artistic skills in a fun and innovative environment. Bricklayer integrates with third-party software including: LEGO Digital Designer, LDraw, Minecraft, and 3D Builder (LeoCAD; `dnf install -y leocad`)
The acknowledgements include "Project Savanna, a group who shares my desire in improving the tooling around SML", with a link to a Slack page that asks for a login. Can you say anything more about this project?
SML comes with many implementations/compilers, but it is one standardized language (with formalized and verified semantics, IIRC).
Does that mean that there is one repository with modules (like PyPI or Maven Central) which all the implementations can use? Is there even a single build tool that can work with all (or at least some) of them (like Maven, etc.)?
A great achievement, but I think that's still running JS in the browser, not SML. Compiling to JS, to be able to run in the browser is not the same as the browsers natively supporting SML code.
You're reusing some components from rust-analyzer, so is there any reason you didn't go with a more query-based/demand-driven architecture, e.g. by also using salsa?
I note in the caveats that the current approach is to recompute everything whenever even one file is changed. But that’s probably not sustainable, as I admit myself in https://azdavis.net/posts/pl-idea-tooling/ :
> As an example, it would be unsustainable if, every time we changed a single function’s body, the language server had to re-typecheck the entire codebase. This might work for an initial proof-of-concept on a small codebase, but for large ones, the responsiveness of the language server would drop precipitously.
>> As an example, it would be unsustainable if, every time we changed a single function’s body, the language server had to re-typecheck the entire codebase.
If only there were a type system[1] where you could reinfer the function’s type in isolation and then recheck all uses!
(I don’t think Trevor Jim’s work on System P2 and System P received any further development, even in “better SML” work like 1ML, which seems like a shame, so I’m going to shill it wherever it appears relevant.)
I had a similar experience with “ Modern Compiler Implementation in ML”… but I didn’t slog through it, I switched to ocaml and ported everything as I went. I’m sure an LSP would have been helpful.
I was introduced to SML in 1996. It has always been a very interesting language, but it never seemed to make it out of academia, which I guess is okay. It seems to have a very nice niche there.
I love the syntax of SML and found the examples of it I've seen online to "click" for me, which isn't the case with OCaml (ugly syntax) and Haskell (can't read it).
Always was a bummer that SML was a sort of dead-end language without a good tooling story.
Hoping Millet doesn't mean anything offensive in any language… Studio Ghibli had this problem mildly with their film "Laputa" ("la puta" = "the whore" in Spanish).
I always thought SML was a great language for teaching computer science and functional programming.
A lot more fun than learning Java. With ML, you got glimpses of aesthetic beauty in code.