News for hackers. Stuff that matters.
Re:Thinking Forth: A Language and Philosophy for Solving Pro... by bitwize on Wednesday February 07, 2024 @11:42PM (#39298252)
> I've enjoyed reading about FORTH and LISP over the years and I think LISP advocates have a similar philosophy.

Want to make a hacker laugh? Say "Forth is the dual of Lisp" to someone familiar with both languages. It seems they reach the same goal of a totally programmable programming language through completely opposite approaches.

Re:Thinking Forth: A Language and Philosophy for Solving Pro... by OldGuyInTheClub on Thursday February 08, 2024 @12:16AM (#39298514)
Well, I hope I don't shanked by one or both sets of advocates.

Years ago I made it partway through this early LISP manual co-authored by a young John McCarthy before his move to Stanford: http://www.softwarepreservation.org/projects/LISP/book/LISP%...

I remember thinking:

1) They did not mess around in the 1960s. No "Hello World," no promises, no sales pitch. Just an in-yer-face "Here's how we do things downtown"

2) They defined a language in terms of itself. I still don't get all that implies but, damn, they can do that?

Re:Thinking Forth: A Language and Philosophy for Solving Pro... by rcbdev on Thursday February 08, 2024 @02:42AM (#39299386)
> They defined a language in terms of itself.

Reminds me of the plethora of compilers written in the languages they're meant to compile. (Roslyn, Java compiler, F# compiler, etc.)

Re:Thinking Forth: A Language and Philosophy for Solving Pro... by dreamcompiler on Thursday February 08, 2024 @06:33AM (#39300743)
But of course it's not the same thing.

The spec for a language is harder to define than the compiler for it. The spec for Lisp is written in Lisp. And it's about half a page of Lisp code. And it's executable, which is not usually true with specs.

This is why reading the Lisp spec feels like reading "the Maxwell's equations of software" (to quote Alan Kay). It's a whole other fundamental model of computation, every bit as fundamental as a Turing machine, but much more practical. Nobody builds serious computing engines out of pure Turing machines, but people do it all the time with McCarthy machines.

Re:Thinking Forth: A Language and Philosophy for Solving Pro... by LAC-Tech on Thursday February 08, 2024 @12:57AM (#39298759)
The LISP 1.5 Programmers manual! Love this one. Your 2) is what Alan Kay called "Maxwell's Equations of Software".

And you're right, there's absolute magic in old computing papers. They were pioneers. I wish we could see more of this pioneering spirit combined with todays silicon and ease of international communication.

Re:Thinking Forth: A Language and Philosophy for Solving Pro... by OldGuyInTheClub on Thursday February 08, 2024 @01:05AM (#39298809)
I imagine my 2012 Macbook Pro feels like Marvin the Paranoid Android given the stonking gap between its capabilities and my actual use of it.
Re:Thinking Forth: A Language and Philosophy for Solving Pro... by packetlost on Wednesday February 07, 2024 @11:58PM (#39298385)
I've thought this same thing before. About the only thing they really agree on is minimal syntax and an implicit stack
Re:Thinking Forth: A Language and Philosophy for Solving Pro... by coldtea on Thursday February 08, 2024 @03:26AM (#39299619)
And creating a DSL for your problem, and user functions being identical to build in functions, and being able to fully extend the language yourself, to the point of adding custom conditionals or whatever, and several other things....

Aside from the functional vs concatenative paradigms, they share a lot of development philosophy, and give a lot of the same superpowers to the developers.

Re:Thinking Forth: A Language and Philosophy for Solving Pro... by flohofwoe on Thursday February 08, 2024 @02:59AM (#39299474)
In my mind, Forth is a "reverse Lisp". Not sure why that's funny though :)

They're both the same basic idea, just that Forth is a much more radical low-level implementation of that idea (e.g. it was just perfect for minimal 8-bit home computers).

Re:Thinking Forth: A Language and Philosophy for Solving Pro... by ctrw on Thursday February 08, 2024 @04:07AM (#39299878)
Lisp is syntax which happens to be executed.

Forth is execution that happens to have some syntax.

If you want a dual of lisp you need to look at Joy or Factor.