by linguae · 2y ago · 0 comments
One of the interesting "what could have been" moments of computing history is Apple's exploration of Lisp in the late 1980s and during the first half of the 1990s. Such projects include:
- Apple's original plans for the Newton, which included an OS written in Lisp.
- The Dylan programming language, which I've heard can be thought of as Scheme with the Common Lisp Object System. Dylan was originally designed to be the official language used to develop Newton apps. Originally Dylan had an S-expression syntax, but this was changed to a more Algol-like syntax due to the prevailing opinion among many that an Algol-like syntax would be easier for C/Pascal/C++ programmers to adopt. However, the Newton ended up using a C++-based operating system, and NewtonScript, which wasn't based on a Lisp, was created as the language for developing Newton apps.
- SK8 (https://en.wikipedia.org/wiki/SK8_(programming_language) ), which was dubbed "HyperCard on steroids," was written in Common Lisp.
In an alternate timeline, we could've been using Apple devices built on a Lisp foundation. This is probably the closest we've gotten to Lisp machines on the desktop, as opposed to specialized AI workstations that cost five figures in 1980s dollars.
Then again, things worked out well for Apple after the NeXT purchase. The OpenStep API (which became Cocoa) and Objective-C was (and still is) solid infrastructure than can be thought of as a "pragmatic Smalltalk" desktop, though in recent years I feel Apple has been moving on from NeXT influences and is doing its own thing now with Swift.
They can be forgiven, at the time. Now we have evidence that thinking is wrong. Today we have half of everyone and their dog, as Web programmers, using a syntax originally chosen by very technical systems programmers. (Bell Labs researchers -> C -> Oak -> Java -> JavaScript.)
Almost no Web developers are systems programmers, and this is just a poor syntax for the work, and needlessly cryptic, but they can pick up even this bad syntax just fine.
Now we know that, whether you use curly braces, parentheses, whitespace, or something else is not the barrier to learning a programming language. It's one of the most absolutely trivial things about it to learn.
Knowing this, the next time I hear someone say "We can't use this syntax, because it will just totally break people's brains, even though the higher grammar, semantics, libraries, domain frameworks, and everything else are different anyway, and are orders of magnitude harder to learn, we need to make it look superficially like something it's not, because people are full of poo"... I'm ready to appropriate the Lily Allen song: https://www.youtube.com/watch?v=KUHqFhnen0U
It seems like Javascript inherits more directly from lisp than any of the other languages mentioned, except for the syntax. As a result Javascript is a lisp without macros, which is a sad concept. (In this sense, I very much agree with you.)
But for people new to the craft, syntax matters: Chris Okasaki found that the one thing that helped students get over the hump and really start to understand scopes and blocks was significant whitespace.
Strangely enough, they found that Lisp syntax was easier to pick up, because it was simpler. (In general, the first word in the parentheses tells you what to do with the rest. Not other punctuation to remember, precedence parsing rules, etc.)
We're usually not developing languages for people with zero experience, but if someone wants to twist my arm to use Lisp syntax...
The C++ like syntax was a kind of honey trap for C++ devs, the actual runtime and language semantics are closer those from Smalltalk/Objective-C, hence why Strongtalk and SELF JIT research did fit so well into Hotspot.
One day the world of computing will realise the mistakes it made and having at least maps of the forks in the road that it didn't take will help it to find its way out of the jungle.
I’m pretty sure by the time I got Sk8 it was download only.
Did this not cripple macros?
That one to two year delay absolutely destroyed any momentum Dylan could have had, and also made implementation of a Dylan-compatible language much more (needlessly) complex for a perceived benefit that never materialized.
Instead of being able to focus on implementing optimizations, tools, and frameworks, everyone trying to participate in the Dylan ecosystem had to spend that time on syntax bullshit instead, and still do. It really pains me that the other Dylan ecosystem players didn't immediately drop the Algol-style syntax for the much simpler Lisp-style one when Apple dropped Dylan, and to this day OpenDylan uses the infix syntax.