6 ms·
Would it be feasible to build a larger application using a language like Factor? I have no experience with concatenative programming, and it seems interesting,
by helix278 2y ago
Would it be feasible to build a larger application using a language like Factor? I have no experience with concatenative programming, and it seems interesting, but I also get the feeling that larger systems would become rather complex and hard to read.
- broken-kebab 2y agoI think questions like this cannot have an objective answer. I dealt with code written in lisps, and Forth. There are plenty of people who claim they are hard to read, but in my experience once your brain starts to recognize patterns, and idioms it becomes crystal clear and logical. At the same time I find myself taking more mental effort parsing code in languages which like to overexplain by repetitiveness, like Java with its "Foo foo = new Foo". I have a colleague however who believes that everything which is not Java is barely readable. Probably, it's related to the fact that he writes Java exclusively for a very long time.
- carapace 2y agoYes, it's feasible. Wielded well (read "Starting Forth" and "Thinking Forth") the concatinative languages are very good for eliminating incidental complexity, so code approaches the Kolmogorov complexity of the problem or task it's for.
- codr7 2y agoFeasible, but takes a lot of skills and hard work to break the problem down into small enough pieces. It's a different way of writing software.
- carapace 2y ago> takes a lot of skills and hard work to break the problem down Same for every programming language. The advantage that concatinative languages have over others is the closeness of their syntax to the semantics of the domain which makes them much easier to learn and use than other PLs (unless one has previously learned the other PLs first. Otherwise PLs like C and Java seem hopelessly baroque.)
- codr7 2y agoI don't agree. All languages fall on a spectrum, different priorities, strengths and weaknesses. Forth is all about simplicity of implementation, it's the number one idea driving every decision. Which means a lot of other priorities, like higher level abstractions, are more difficult to achieve. It does make a nice DSL sometimes, so does Lisp, to an even greater extent, while providing plenty of higher level abstractions.
- carapace 2y ago> A simple solution has elegance. It is the result of exacting effort to understand the real problem and is recognized by its compelling sense of rightness. I stress this point because it contradicts the conventional view that power increases with complexity. Simplicity provides confidence, reliability, compactness, and speed. ~ Chuck Moore, from "Starting Forth" foreword. https://www.forth.com/starting-forth/0-starting-forth/ https://www.forth.com/starting-forth/0-starting-forth/ > It can scarcely be denied that the supreme goal of all theory is to make the irreducible basic elements as simple and as few as possible without having to surrender the adequate representation of a single datum of experience. ~ Einstein https://quoteinvestigator.com/2011/05/13/einstein-simple/ https://quoteinvestigator.com/2011/05/13/einstein-simple/ > a lot of other priorities, like higher level abstractions, are more difficult to achieve [in Forth] I'm not a Forth person myself but if I were I would challenge you to name a higher level abstraction or other priority that was difficult to achieve in Forth, or perhaps, more topically, in Factor.
- codr7 2y agoCLOS or Conditions from Common Lisp then, or LINQ from C#, or sum types. And I don't mean something that looks sort of similar; I mean the same functionality, flexibility and level of convenience.
- carapace 2y agoLike I said, I'm not a Forth person, but if there were any around to settle it I would bet you all those things have several implementations (I do know that many people have written OOP and OOP-like things in Forth.) > I mean the same functionality, flexibility and level of convenience. I feel like you're missing the point (although there's such a thing as ANSI Forth so you are in good company). In Forth re-implementing an exact model of some other system (like CLOS, which is, of course, very nice, I don't need to tell you) is a non-goal (you could do it but it would be kind of a stunt.) The fundamental advantage of concatinative languages over pretty much all the other PLs and paradigms (except maybe Smalltalk and APL) is that they permit parsimony of code, what some have called "semantic compression", by refactoring better than other languages. One of the reasons Lisp is so powerful is that it's also pretty good for refactoring. I could prove this using Category theory (and God willing someday I will), concatinative languages are closer to the metal (the "metal" in this case being, not the hardware, but the conceptual essence of programming and logic.) Anyway, well met, and have a good week. :)
- foretop_yardarm 2y agoHere’s a somewhat related, albeit casual, read - if you’re curious: https://groups.google.com/g/comp.lang.forth/c/ThWiGXwKqv4 https://groups.google.com/g/comp.lang.forth/c/ThWiGXwKqv4
- ralphc 2y agoThis is called "A Forth Story" I want to like and use Forth for something, but this from the post sums it up pretty well. "I told my partner that the final device could not be programmed in Forth. Why would I say such a thing? Simply because technology had passed Forth by, in my opinion. It was no longer possible for one person to develop all the software required in a graphical environment. I needed to buy the tools I needed to leverage my time for a professional job. I could no longer play the role of the maverick programmer, nor did I want to. I need to be part of a collaborative community in which I can give and receive work. I do not see Forth as a viable solution as of today." That was 1995. His "story" also ended in 1995 with him being unemployed. The author is Allen Cekorich, which made it easy for me to look him up on LinkedIn and see what happened after. Yes, LinkedIn is good for something. Sounds like he landed on his feet. https://www.linkedin.com/in/allen-cekorich-a86aa731/details/experience/ https://www.linkedin.com/in/allen-cekorich-a86aa731/details/...