Announcing Dotty 0.14.0-RC1

#1

Hi everyone! Today we’ve released Dotty 0.14.0-RC1. This release brings some new features such as the export keyword meant as a dual of import, the creator applications syntax and a bunch of others.

You can learn more about the changes from the blog post: https://dotty.epfl.ch/blog/2019/04/15/14th-dotty-milestone-release.html

Notable Changes

Syntax

  • Add Export as a Dual of Import #6169
  • Implement creator applications #6084
  • Change syntax of splices and quotes #5918

Features

  • Add the method #5893
  • Add an immutable array type #5885

Issue Fixes

  • Fix #6007: Get the classloader that loaded the application #6017
  • Fix #3248: support product-seq pattern #5989

Other

  • Don’t uncondtionally emit forwarders as ACC_SYNTHETIC #6173
  • Simplify Scala 2 trait support #6040
  • Move Staging to Typer #5846

Contributors

Thank you to all the contributors who made this release possible :tada:

According to git shortlog -sn --no-merges 0.13.0-RC1..0.14.0-RC1 these are:

   230  Martin Odersky
   174  Nicolas Stucki
    74  Liu Fengyun
    55  Guillaume Martres
    26  Olivier Blanvillain
    12  Aleksander Boruch-Gruszecki
    10  Aggelos Biboudis
     9  Anatolii Kmetiuk
     8  Miles Sabin
     4  Dale Wijnand
     4  Allan Renucci
     2  Lionel Parreaux
     2  Alex Zolotko
     2  Fengyun Liu
     1  tim-zh
     1  Jim Van Horn
     1  Jentsch
     1  Jasper Moeys
     1  Master-Killer
     1  Ignasi Marimon-Clos
     1  Dotty CI
     1  Dmitry Petrashko
     1  Olivier ROLAND
     1  Robert Stoll
     1  Seth Tisue
     1  Sébastien Doeraene
     1  Tomasz Godzik
     1  Victor
     1  gnp
     1  Johannes Rudolph

Reporting Bugs

If you encounter a bug, please open an issue! :pray:

4 Likes
#2

Thx to Anatolii Kmetiuk for coordinating this release!

#3

I am glad about the update, but what bothers me is that you introduce new keywords. I had hopes that Dotty would focus on simplification instead, as complexity is the main barrier for switching to Scala and we see that Scala’s popularity is declining (see latest TIOBE index). I understand that new keywords can be useful for experienced Scala developers but they can scare others off.

#4

I just have to point out the TIOBE is probably the worst of all the programming language indices. A year or so ago they made a big deal because F# jumped way up in their ranking. Now it’s gone back down. That type of volatility means it is next to meaningless. RedMonk (https://redmonk.com/sogrady/2019/03/20/language-rankings-1-19/, https://redmonk.com/rstephens/2019/03/20/redmonk-top-20-languages-over-time-january-2019/), IEEE (https://spectrum.ieee.org/static/interactive-the-top-programming-languages-2018), and PYPL (http://pypl.github.io/PYPL.html) are much better rankings, IMO. In all of those, Scala has been holding steady in the 12-15 range for several years now.

Having said this, I’m not a huge fan of introducing new keywords to Scala. I really would like to see the language be simplified as much as possible, but I think we have also seen that the “small set of orthogonal features” can lead to confusion as there are potentially too many ways to accomplish certain things.

What I would really want to preserve in Scala is the idea of having “levels” to Martin described many years ago. I teach Scala to novice programmers and it works well because you can do all the introductory programming stuff with scripts and a fairly non-complex subset of the language. There really is a version of Scala that is mostly self-contained that is almost like statically typed Python. This is what I think we need to maintain. As long as the new keywords and added complexity go at different levels and can possibly even be spread out across levels, I think that we are fine.

What needs to happen then is having materials that present Scala to new people in an appropriate way, growing in complexity as the developer needs it and not trying to throw the whole language at them right off the bat.

3 Likes
#5

I think this is the wrong way to think about it. One of the main problems I’ve seen with inexperienced Scala developers is that the catch-all keyword “implicit” means a number of different related concepts, which both confuses and scares people. Breaking that out into more-focused concepts seems likely to make it a bit easier to learn, IMO.

Besides, I don’t think there is any clear evidence that number of keywords is related to either the popularity or ease of learning a language. Conceptual simplicity matters, but folks tend to pick up keywords without even noticing them.

Agreed. I’ve actually been toying with the idea of drafting a strawman version of updated levels (both adding new stuff and removing several things that IMO don’t belong there any more), for us to discuss – while they’re not hard-and-fast, I think they make a useful shorthand, especially when teaching folks and discussing pedagogy, and help emphasize that “learning Scala” generally should not mean learning all of Scala in most cases…

4 Likes
#6

As far as a beginner is concerned println might as well be a keyword. The number of keywords in the language is most certainly not a pressing concern for beginners.

1 Like
#7

It’s probably old news, but IntelliJ IDEA 2018.2 can help a lot with implicits: https://blog.jetbrains.com/scala/2018/08/17/how-to-use-the-new-features-of-intellij-scala-plugin-2018-2/

Maybe after analyzing some examples with hints from IntelliJ people would develop proper intuition more quickly?

#8

IMO this is definitional to what Scala is. Sure there’s a tradeoff between buying a ready-made item and a DIY kit. It’s the tradeoff between convenience and freedom. If I didn’t value flexibility I might not be using Scala.

I don’t understand the issue with having multiple ways to do something, as long as all the ways work, unless we’re talking about a perfectionist struggling with choice paralysis. (Personally I hit this more when writing prose than writing Scala, though). Excluding that, if there are two ways to do something and you can’t decide, just flip a coin or something. The real problem is when there are too many paths to take and you don’t know which of them even lead to where you need to get to at all. Yes this is more of an issue in a “small set of orthogonal features” language (hence the importance of “small” in that phrase), but IMO it ultimately comes down to a good understanding of the features, which comes down to good documentation, as well as ensuring those features are as simple as possible and interact as unsurprisingly as possible.

Of course, it’s not a binary choice; we could make the features somewhat less orthogonal. But if you turn the dial too far, you’re talking about a fundamentally different language, even if it has mostly the same syntax as Scala.

In any case, I’m not clear how this relates to the thread – does Export affect feature orthogonality?

1 Like