11 ms·
Since I've been interested in how the Functional paradigm might help us developers deal with concurrency, there are 2 items here that really strike me: 1.) Clo
by lkrubner 10y ago
Since I've been interested in how the Functional paradigm might help us developers deal with concurrency, there are 2 items here that really strike me:
1.) Clojure fell back
2.) Elixir, though small, is still moving forward
I've been a fan of Clojure since 2009. It grew rapidly for a few years, from 2009 till at least 2014. It has stalled out. This makes me sad because I've loved working with it and I think it a great community, in most ways. But it is true that the community has been unable to answer some of the criticisms leveled against it. The reliance on Emacs has meant it is not easy for beginners. On the other side, the elite (the purists?) have wanted to see Clojure be more like Scheme, or more like Racket, or more like Haskell. Clojure has offered up many interesting ideas, but perhaps hasn't quite built a complete eco-system that makes it broadly appealing.
Elixir, though very small, still seems to be moving forward, and perhaps has a chance to answer some of the demands that people made of Clojure (more pure? easier syntax?). Maybe Elixir is the language that make the Functional style the dominant style in computer programming?
- sotojuan 10y agoElixir's doing very well for its age—before 1.0 it had four books, a conference, and a dedicated video series. With the rise of Phoenix there's quite a lot mire of resources for it.
- davidgrenier 10y agoI don't think it matters much what these charts say as long as they do not measure merit and Clojure has a lot of it. You can use it irrespective of how an ill-advised majority of developers think Javascript/Node/Angular is good.
- lkrubner 10y agoPlease think about what you are saying when you write "You can use it irrespective of how an ill-advised majority of developers think Javascript/Node/Angular is good." Most of the places I work will only allow the use of a language that is in the top 10. I am not allowed to introduce Clojure, because it is not popular enough. But if I told management "We should use Angular" that would be an easy sell. You sentence would be more accurate if you had simply written: "You can use Javascript/Node/Angular irrespective of how good they are, but you can't use something that is great because a sometimes ill-advised majority of managers base their decisions on their estimate of future risks."
- airplane 10y agoRegarding the reliance on Emacs, might not be the case anymore. When I was new to Clojure, I immediately used an IntelliJ plugin called Cursive. It was/is great, same experience as writing Java in IntelliJ. (https://cursive-ide.com/ https://cursive-ide.com/)
- city41 10y agoBut the problem is you really do need a "paredit" for your editor when developing in Clojure. It's a double whammy for beginners, and a huge one at that. Pretty much every other language ever is perfectly editable in everyone's editor as it exists today.
- bad_user 10y agoCursive does have a paredit mode. Works OK for me.
- nazgob 10y agoEven Atom has nice "paredit" right now. It's not an issue anymore.
- city41 10y agoMy point is you have to use a paren tool to keep lisps sane. That's not true of any other type of language. So when trying to introduce someone to clojure, they see not only a very strange language but a new tool requirement as well. It really creates barriers to entry.
- JBiserkov 10y agoAs a beginner I found that learning a single keyboard shortcut - Ctrl+W - "expand the selection to the surrounding semantic unit" was a huge productivity boost (the opposite action is Shift+Ctrl+W). Coupled with the setting "Settings→Editor→Smart Keys→Surround selection on typing quote or brace." it's amazing.
- Jach 10y agoYou don't even need a full-blown "paredit", just the ability to jump back and forth between different kinds of opening and closing braces. I've been using vim for Clojure exclusively since I first started dabbling with it in 2011, I'll die before succumbing to emacs... A bigger issue though is that to really sell Clojure you need to sell the alternate mindset of developing it represents as a lisp. With emacs, you can assume slime, and immediately you're exposing people to developing their code iteratively instead of the traditional approach of edit file, save, run from scratch.^1 With every other editor you need to first give beginners^2 something to approximate slime^3, or else you're going to present developing in Clojure the same as you'd present developing in Java, which is to say you'll lose a lot of the punch. ^1 As an aside this is why I'll never be satisfied with plain Java/JavaScript no matter how many new static features they get so long as they remain fundamentally opposed to the build-up style of programming. ^2 By beginner I mean to Clojure; I don't think Clojure is a good language for programming beginners. It is suitable for people as a second or later language, but not their first. So basically I agree the need to explain the preferred editing environment is a hurdle -- if the person's first language was Scheme, maybe there wouldn't be a problem since you don't really-really need paredit or syntax highlighting or auto-indent or anything besides the ability to edit and save text. ^3 For me that's just a separate terminal in a screen session that a vim plugin talks with, though there are others (and probably better, I haven't tried them seriously) for vim.
- marpstar 10y agoClojure (and ClojureScript via Reagent[1]) is what got me into functional programming in the first place. However, as a developer working in a .NET shop I found more opportunities (e.g. .NET interop) to do "functional programming" in F#, which has also been well support cross-platform for some time. At the time, Leiningen was still in its infancy and I hit a lot of issues getting things running but when I finally did the language had a profound impact on me as a developer. [1]: https://reagent-project.github.io https://reagent-project.github.io
- megalomanu 10y ago"the language had a profound impact on me as a developer." I think Clojure will remain in the developer culture for that. Clojure will be recognized for its action in LISP resurrection and functional programming renaissance. It's often said that "The Velvet Underground's first album only sold a few thousand copies, but everyone who bought one formed a band.". It's the same for Clojure: there will be never a lot of apps, but I'm pretty sure that all the developers who learned Clojure became better developers, developed good libraries in other languages, started a blog, etc.
- j10sanders 10y agoAlong these lines, is there any reason I shouldn't learn Racket instead?
- city41 10y agoI think ClojureScript could benefit my team as both a productivity and performance boost. But convincing a large team to switch to a lisp is pretty much never going to happen. I might as well try to get everyone to switch to dvorak keyboards while I'm at it.
- fierycatnet 10y agoI am not sure why Clojure is "stagnating". I don't think it's about Emacs, we have Cursive now which is very powerful and runs on top of IntelliJ. Clojure also is picking up in webdev. A new book just came out from Sotnikov, Arachne was announced recently, Om is being worked on, couple of different screencast series are being made, etc. I am not a seasoned developer but I like Clojure and I am sticking with it because it makes sense to me. I think it's an awesome language and I wish more people would try it and develop in it.
- pjmlp 10y agoI am yet to do any web development project where the customer allow us to use anything other than JavaScript, eventually TypeScript but only because it is a Microsoft language.
- pjmlp 10y agoI will be blunt and state that neither of them matter. Some people might hate Java and search for alternatives on the JVM, but 90% of the production code on the JVM, its commercial variants, and Android is plain Java. Also ClojureScript is not 100% Clojure and most web shops across the world only care about JavaScript. Likewise, the majority of developers targeting BEAM will be using Erlang. If something I learned from my Turbo Pascal/Delphi, Oberon experience, is that programming languages that aren't considered a first class experience from the platform owners never manage to get a significant market share, long term.
- geodel 10y agoI agree and add even 90% sounds like conservative estimate. One reason I think is Java is good enough and the incredibly loud communities of smaller JVM languages have not produced enough libraries, tooling etc to attain a 'just works' title which is needed for most common type of development done by salaried workers.
- s_kilk 10y agoA few (rambling) thoughts, as a long-time Clojure dev who's recently been focusing on Elixir. The thing I like most about Elixir is the low friction between it and it's host language, Erlang. Erlang is a functional language right from the start, and the BEAM is designed to run a functional language, which means you never hit the weird FP-OO barrier that comes up so commonly in Clojure. I really think the impedence mismatch between Clojure and the underlying Java implementation is a big, painful problem which is going mostly unacknowledged by the inner-core of the Clojure community. And that makes sense, because they're all (or mostly) "Java Guys" who are already sold on the Java ecosystem and are fine with there being a layer of spindly OO horror in their projects. They don't mind the Java layer poking through in unpleasant ways. When I bring this up in a congregation of Clojurists I just get "shrug, welp, Clojure is a hosted language", not even an acknowledgement that there may be a problem worth discussing. For the rest of us, the FP enthusiasts who don't have an emotional or professional attachment to Java, this sucks, because you can't do much in Clojure without also touching Java. As I said at the start of this ramble, Elixir/Erlang don't suffer from this problem, it's FP all the way down. Erlang idioms fit in with Elixir, and vice versa. No friction, no bullshit. One final point: I think the Elixir team visibly care about ergonomics and good design, much more than the Clojure team seem to. Look at `mix` and compare it to `leiningen`, honestly. Look at Plug and Phoenix and compare to something like Luminus in Clojure-land. The difference is night-and-day. Look at how fast the `iex` repl boots up, or how fast the stop-compile-start workflow is in a Phoenix app. Even look at the content of the languages respective homepages (http://elixir-lang.org http://elixir-lang.org and http://clojure.org http://clojure.org)
- sheepmullet 10y ago> When I bring this up in a congregation of Clojurists I just get "shrug, welp, Clojure is a hosted language", not even an acknowledgement that there may be a problem worth discussing. I'm not quite sure what you are expecting. It is a tradeoff they explicitly made. I've yet to see another platform come close to rivalling the JVM ecosystem. It is a powerhouse. I think it's a great tradeoff. From a team and organisational productivity point of view unless you are based on either the JVM, the CLR, or have fantastic c/c++ interop you are dead in the water.
- megalomanu 10y agoI also dropped Clojure/ClojureScript, even though it was my favorite language between 2012 and 2014/2015. The main reason for me is the progression of Java and JavaScript during these years, which make ClojureScript less useful. ES6 has completely transformed the JavaScript development. I finally enjoy to code in JavaScript - this wasn't the case before. On the contrary, coding in ClojureScript became painful. It's difficult to follow the recent trends, to integrate new libraries without hassle. Currently I work on a project that use DraftJS. I don't want to know how to integrate it in ClojureScript ! It's a waste of time, and again the "joy of Clojure" still exists but is now less superior to the "joy of Javascript". On the Clojure/JVM side, Java 8 is far from perfect but the lambdas expressions have made the language a bit less boring. I think many developer feel less the urge to leave Java for an alternative language. And if they really want it, there is Scala, still the best strong statically typed language on the JVM, and so, for me, still the best language for backend development. In short, Clojure/ClojureScript was for me the best language for rapid prototyping and for front development. I've never really considered it for "serious" backend applications based on a complex data models, because of its dynamic typing. However, JavaScript development became much more pleasant, making ClojureScript less attractive, less differentiating. I believe that today, you have to be a true Clojure fan to code in ClojureScript.
- BigPicture4TW 10y agoScala is a fine backend language, with far more bells-and-whistles than Java 8. However the comparison beyond language features is very much relevant, including the lack of Android support in Scala 2.12 Adding to the woes, the code emitted by 2.12 is slower ( https://news.ycombinator.com/item?id=12066653 https://news.ycombinator.com/item?id=12066653 ) Not to say things can't improve. After the initial announcement of 2.12 at ScalaDays 2015 and 2016, expect more at ScalaDays 2017.
- pjmlp 10y agoThe Android team did a AMA on Reddit this week, they were pretty clear that regardless of people wishes only Java, C and C++ matter on Android. Anything else it is up to the respective language communities to make it work. Right now only Kotlin seems to be improving their Android support, but that is because JetBrains needs a killer application for it, which appears to be improving the world of those stuck in Java 6.
- _pmf_ 10y ago> It has stalled out. I guess the patronizing and uncooperative attitude towards the community plays its part. If you don't accept Rich Hickey and Relevance / Cognitect / whatever they call themselves nowadays as the ultimate source of wisdom, your opinion is worthless and you're "Doing It Wrong™". But on the other hand, they're very much keeping the tradition of the of the Smug Lisp Weenie alive, albeit as a caricature rather than a rebirth.
- GFK_of_xmaspast 10y ago> But on the other hand, they're very much keeping the tradition of the of the Smug Lisp Weenie alive, albeit as a caricature rather than a rebirth. First as tragedy, then as farce.
- sorpaas 10y agoClojure worked for me until I started to do parallel programming. I tried to use core.async but immediately found that I'm using two distinct style of programming, and code reuse became a serious problem. I didn't find any resources on how other Clojure programmers deal with this problem, but this eventually lead me to drop Clojure and Clojurescript, and use Elixir and Elm instead.
- s_kilk 10y agoFunnily enough, this is exactly what lead me from Clojure to Elixir. Parallel programming in Clojure is nowhere near as well developed as the glory of OTP on the Elixir/Erlang platform.
- jeremiep 10y agoI don't feel like clojure stalled out. You have to realize the redmonk rankings are using very weak heuristics to get these results. I'd rather choose languages and tools by how much they match the problem space rather than how popular they are at any particular point in time. If you trim out all the worthless SO questions/anwsers you'll get radically different rankings on redmonk. JavaScript could very easily drop from its first place doing just that. I don't get why people chase popularity in programming languages. That's what you do in a pop culture, not in an engineering one.
- lkrubner 10y agoAbout this: "I don't get why people chase popularity in programming languages" I am forced to do this simply because I consult at companies where the managers do exactly this. They will not let me use a language unless it is a top language. If I say "Clojure would be excellent for the project that you have in mind" they will reply "We can not use Clojure because it is not popular enough. We have to use a language where there is a large pool of developers that I can hire, and there is no risk that the language will disappear in 5 years."
- jeremiep 10y agoI can understand in these environments they want to limit risks. And because the work is boring and the conditions are average to begin with, these companies are always on a massive roll of junior developers. It's especially bad if code isn't their main area of expertise. I've seen companies of 300-500 employees struggle to keep even a single senior programmer over half a decade. They'd get far more talent by actually embracing an engineering culture. What I always see is that the juniors start getting experience, realize the place they work at is a huge pop culture and leave for an engineering one, thus lowering the talent pool of said company. Basically they don't want smart engineers, they want replaceable code monkeys. They have yet to realize there's a few orders of magnitude worth of quality and productivity between the two. I used to work in such an environment until I had enough of this cancer and decided to move to a small studio with less than 30 employees but with a very strong engineering culture.
- Roboprog 10y agoRegarding FP: My daughter is a (non CS STEM) student at UC. She knows one language: "R". (I tried to get her to learn Python in high school, but it never took) While R is certainly not a general purpose language (yet?), it is very much an FP type language, and gaining in popularity. I have only tinkered with it a little, but it looked pretty sound.
- schofar 10y agoRegarding R and its soundness (in the general colloquial sense), here's something that bothers me about it (scope leakage): > if ("blah" == "blah") { y = 2 x = y + 2 } else { x = 1 } > x 4 > y 2 I really wish what I introduce in my blocks would stay in my blocks...
- Roboprog 10y agoIf that's the worst issue, I'm not seeing much of a problem. I guess I'm not particularly hyped about intro of "let" (block scope) into Javascript, vs "var" (function scope), either, but it bothered somebody enough to need "let". Does R have an "IIFE" type construct, similar to JS or Golang?
- hellofunk 10y agoFull time Clojure dev here who has been transitioning to non-Clojure projects recently, for two main reaons: 1) I've decided that static typing is the world I want to program in, for a wide range of reasons. 2) The JVM (and JS) have their limits, and Clojure is just not as portable as I'd prefer. Otherwise, I learned a lot from working with Clojure over many hundreds of programming hours, and it is an impressive feat of engineering, but it's limitations are insurmountable at this point.
- ngrilly 10y agoWhat do you use instead?
- hellofunk 10y agoC++ and recently, Haskell. A lot of what I learned in Clojure I can now use in C++ since the C++14 version of the languages supports a lot of functional programming techniques (though not thoroughly). C++ today is not the language it used to be, and the ability to write and use standard library higher-order functions with my own simple anonymous functions is really nice.
- ngrilly 10y agoInteresting. Thanks for sharing.