5 ms·
The first time I read about Prolog, I thought to myself, "Man, this is what computing was supposed to do for us! Look at it answering questions, doing planning.
by angersock 12y ago
The first time I read about Prolog, I thought to myself, "Man, this is what computing was supposed to do for us! Look at it answering questions, doing planning...holy cow."
And in the last 40 years? Maybe Erlang (a Prolog descendant), Ruby (maybe the best successor to Lisp/Smalltalk), or Elixir (an Erlang descendant looks like Ruby) is as impressive. The rest is either hacky (C++, Javascript, Perl), attempts to clean up hackiness (Java, D, Go, Rust, Clojure), unoriginal (Python, C#), or just plain wanky (OCaml, Haskell)--and that's not counting ones that are beneath mention (PHP).
Don't get me wrong...there are some languages that are actually quite beautiful in their implementation or use (Lua, Clojure, a few others), but the "holy shit this is the future!" feeling I get from looking at Prolog, Erlang, or Ruby is something I haven't had in a while.
Instead, the future of practical programming languages is probably going to be yet another tepid iteration on Algol, with closures and memory safety and incorrectly-handled numerical safety and some lame concurrency story. Pattern matching if history is slightly kind to us, probably still no mandatory tail-call optimization. Sigh.
Go is the future, I guess?
- walterbell 12y agoWhat do you think of Awelon? https://github.com/dmbarbour/awelon/blob/master/AwelonProject.md https://github.com/dmbarbour/awelon/blob/master/AwelonProjec... "My goal is to unify programmer experience (PX) with the user experience (UX). This is an elusive goal. It has been pursued for many years, with many different hypotheses for what such a unification might entail and how it might be achieved. Related projects include Squeak Smalltalk, ToonTalk, LambdaMOO, Morphic, Croquet, Emacs, and HyperCard. A relatively successful effort to unify PX and UX was the Unix command line, where users would build short programs of process pipelines. But that has been marginalized by the development of GUI. To me, the unification of PX and UX means that programming becomes a casual effort, such that users make it part of their normal workflow and don't even think about it as programming."
- agumonkey 12y agoWeird, I read some of dmbarbour's articles from a RSS feed, but I never read the basis for its awelon project, basis that have been an obsession of mine for quite a while. Thanks.
- seanmcdirmid 12y agoThe problem of Prolog is basically the history of AI: curated logic has mostly failed to live up to expectations and given away to various machine learning techniques. The Prolog approach was blamed for the second AI winter; Japan bet big on it in their 5G computing project (and lost big on it also) [1]. However, the paradigm lives on and is quite successful in various rule-based business logic systems; it just isn't very appropriate for general computation. Plenty of languages try to invent the future, but they are quite research projects in the spirit of the original prolog (which wasn't even implemented until it went into someones dissertation). The languages that actually hit production are quite conservative in comparison, since they kind of have to be. Anything more radical, you might just write off as even more wankier than OCaml and Haskell. Go is the present, perhaps, not really the future. [1] http://en.wikipedia.org/wiki/Fifth_generation_computer http://en.wikipedia.org/wiki/Fifth_generation_computer
- Chinjut 12y agoWhat does "wanky" mean in this context?
- andolanra 12y agoI think a charitable reading is 'excessively academic and not concerned with the real day-to-day aspects of programming', which is a common characterization of languages like Haskell and OCaml, albeit one I'd contest. (A less charitable reading, on the other hand, would likely invoke the commonly-cited Blub Paradox from http://www.paulgraham.com/avg.html http://www.paulgraham.com/avg.html )
- angersock 12y agoSo, that's not entirely it, though thank you for the opportunity of introspection. The reason I say "wanky" is that there doesn't seem to be in the popular rhetoric a clear practical reason for their existence beyond "we need this language". C? "Writing assembly sucks". C++? "Writing C for large project sucks". Java/D/C#? "Oh god C++ is worse than we thought". PHP? "We need to write web servers". Perl? "We need to munge strings". Ruby? "We need to be happy, and long-term exposure to Perl prevents that". COBOL? "We need to write a lot of business software". VB? "We need to write a lot of business software, and are on the MS stack". Fortran? "We need to write a lot of numerical code, and it has to be fast". Erlang? "We need to write distributed, fault-tolerant systems and all we have is C and Prolog". Elixir? "Erlang is awesome but hurts our eyes". APL? "We don't have computers yet, but we still need to write about them". Lisp? "We also don't have computers yet, but we could maybe implement our way there". Ada? "Wow, we can't trust C programs for anything". R? "We need to do statistics". Lua? "We need to be easily embeddable, and Brazillian." The same can be said about Smalltalk, SQL, Javascript, Eiffel, and many other languages. Even academic languages and systems (Scheme, ML, Coq, Simula, Io) were exploring something in particular. Hell, at least Elm had the clear objective "We want to be Haskell, but in the browser". Haskell? Haskell seems to be mainly "man, we should define a standard compilable functional language". Its syntax is nothing special if you've been exposed to other ML-descended languages (OCaml, F#), or a language (say, Erlang) which allows pattern-matching. Its a compilable, statically-typed, lazily-evaluated functional language with immutable data...which is not super interesting if you've seen or dealt with other languages. The bigger problem I have, honestly, is one of branding. The Scheme folks never pretend that theirs is a language that will save programming, merely an exercise in purity and peacefulness like a sort of digital taoism. C programmers, on the whole, never pretend that their language is anything more than the moral equivalent of moving a mountain with only a spoon and stern frown. Java and C# programmers don't seem to claim to be anything more than a sort of Stalinist human wave tackling the problems of enterprise. Even the Rubyists and Javascript programmers have a sort of cheerful guilty pleasure that they get paid as much as they do to have fun with computers and the Internet--and they never claim to be some sort of evolutionary step in computing. Haskell programmers, though? Haskell folks? Every one of them that I've chatted with seems to be cut from basically the same sort of cloth: quite smart, rather academic, and pretty much useless for any sort of real production programming. Theirs does not appear to be a culture well-suited to product development, to software engineering, to simple explanation or acceptance that most products and business needs are best met with tools of expediency instead of beauty or purity. Indeed, as outlined above, I find many Haskell people seem to be using a tool few care about to solve problems nobody has in ways that have been solved before, all the while viewing themselves as intellectually superior to the lesser "blub" programmers who are, you know, getting paid, and working on projects way more interesting than whatever the Haskell folks are posting on /g/ about.
- agumonkey 12y agoIdris and its siblings is quite futuristic. Prolog (and other logic programming like kanren) was even weirder than that, it felt timeless; out of the map. Seeing demos of embedded interpreters for inverted evaluation was unbelievable.
- ScottBurson 12y agoProlog never delivered on the promise of declarative programming, because its rigid, unintelligent depth-first search strategy makes it necessary to understand the execution model and keep it in mind when writing programs. So it's only mostly declarative. Prolog achieved some popularity because there are times when brute-force depth-first search is all you need, particularly if it can be done very fast; but once you bump against the limitations of that paradigm, Prolog is of little help. True declarative programming is still an open research problem.