News for hackers. Stuff that matters.
Re:Forth: Stack-Manipulation Operators by haolez on Friday May 14, 2021 @02:44PM (#27158170)
Forth has almost no syntax, which leads to every project becoming some kind of domain specific DSL. This is not necessarily a problem, but it leaves Forth without a strong sense of identity as a programming language. This is my opinion, of course.
Re:Forth: Stack-Manipulation Operators by Someone on Friday May 14, 2021 @05:22PM (#27159853)
Not only your opinion. It is fairly common among Forth enthousiasts to talk about “a Forth”, rather than “Forth”, as two Forths can be hugely different, yet be recognized as Forths (lisp is similar in that regard)

The ideal system is optimized for its problem domain. That means not only adding needed functionality, but also dropping unneeded functionality, and tweaking functionality to better fit the problem at hand. That’s not surprising for a system that shines when running with very little memory.

That’s different from, say C++. Nobody says clang, gcc and Visual C++ are “a C++”.

If they were philosophically similar to Forths and Lisps, those writing programs in them would be happy to change int promotion rules, operator precedence, vtable layout, etc, and different compilers would make different choices there.

Re:Forth: Stack-Manipulation Operators by liberalbias998 on Sunday May 16, 2021 @06:50AM (#27172748)
There are really only two complete, commercially supported FORTH implementations out there; and they implement the same standard. So there are far fewer FORTHS out there than people think.
Re:Forth: Stack-Manipulation Operators by macintux on Friday May 14, 2021 @04:35PM (#27159406)
Presumably that’s compounded by the fact that the inventor, Chuck Moore, feels strongly that Forth is more of a concept to be reimplemented for each project, customized along with the hardware, than a programming language to be standardized.
Re:Forth: Stack-Manipulation Operators by throwaway17_17 on Friday May 14, 2021 @06:06PM (#27160199)
Moore’s talks and quotes of his from various lecture notes on this point really inspired the underlying theory of my personal programming language. I wanted something that I could adapt to different use cases when I saw fit, but with a solid underlying theoretical base. I have been using it for my personal work for about 8 months now (compiling to JS, C or C++ depending on project) and I’m enjoying it greatly as well as being productive.
Re:Forth: Stack-Manipulation Operators by macintux on Friday May 14, 2021 @06:16PM (#27160279)
Do you have a blog post about your language? If not, you should write one.
Re:Forth: Stack-Manipulation Operators by throwaway17_17 on Friday May 14, 2021 @07:55PM (#27160929)
I don’t at this point. I have been playing around with the idea of a release or something similar. But people tend to expect a lot when a new language is shown. I don’t know if anyone would be interested in just reading about the language and then not even being able to use some light playground or anything.

I have been considering doing an Ask HN to see what people felt should be included on an initial ‘release’ or showing of a language. Maybe I should.

Re:Forth: Stack-Manipulation Operators by macintux on Friday May 14, 2021 @08:16PM (#27161059)
Just a description of your philosophy and how it and the language have evolved would be interesting, along with some sample code (and sample output), regardless of whether you eventually release it.
Re:Forth: Stack-Manipulation Operators by zzo38computer on Saturday May 15, 2021 @02:34AM (#27162965)
Do you have any documentation? I might want to see, maybe.
Re:Forth: Stack-Manipulation Operators by bear8642 on Friday May 14, 2021 @07:21PM (#27160703)
> Forth has almost no syntax

Feel more Forth has no syntax - just space separated words defined either in assembly or other forth words

Re:Forth: Stack-Manipulation Operators by thewakalix on Saturday May 15, 2021 @02:17AM (#27162883)
Isn't "space-separated words" a syntax, albeit a minimal one?
Re:Forth: Stack-Manipulation Operators by zzo38computer on Saturday May 15, 2021 @02:47AM (#27163009)
I think so, and some words will read additional text other than treating as words (such as comments, text strings, etc). Still, it doesn't have a syntax as much as other programming languages do.