Mark "Justin" Waks
2 min readFeb 19, 2019

--

I can understand your view here; I disagree, but I think that’s a matter of how you think about language evolution.

Consider a language as a product. In that view, this is a classic argument, of completeness of features vs. streamlining and comprehensibility. (It’s the stereotype of the Microsoft vs. Apple debate.)

It’s easy to argue to keep every feature, since somebody is always using it. But that comes at a constant long-term cost of complexity and difficulty of entry.

So the pressure in the opposite direction is streamlining — that every feature must “fight for its life”. That’s just as strong a question for existing features as prospective ones — if you wouldn’t add that feature now, knowing what you now know, why should it stay in? It’s adding a constant weight of maintenance and complexity.

Removing features is always hard and dangerous, but the once-a-decade (if that) major-version bump is the right time to do so, IMO. Streamlining shouldn’t be done casually, and indeed, many of these changes are being actively debated on the Scala Contributors Forum, which I commend to anyone interested in the topic. But it’s worthwhile on general principles for the same reason that refactoring is: making the system able to do the same things more elegantly is a net good in and of itself.

IMO, the replacement of package objects with top-level definitions is a pure win: assuming it’s done right, it will remove a misfeature that many people have long thought was a language wart with something that accomplishes the same goal in a better way. I’d say the jury is still out on early initialization: it is rare, hard to learn, and an annoying detail that feeds into the “Scala is too complicated” meme, so I’d like to see it replaced. But it isn’t yet quite obvious to me that all of its use cases have better answers.

But overall: the whole point of Scala 3 per se is to be able to make significant changes like this — that’s what makes it different from a normal language version. A fair chunk is being refactored. Yes, that will mean some rewriting of code — that’s why Scalafix is such an important part of the equation. But in the long run, the objective is to get a language that is more consistent, and easier to learn and comprehend, than what we have now. IMO, that’s a fine goal…

--

--

Mark "Justin" Waks
Mark "Justin" Waks

Written by Mark "Justin" Waks

Lifelong programmer and software architect, specializing in online social tools and (nowadays) Scala. Architect of Querki (“leading the small data revolution”).

No responses yet