Be notified of new releases
Create your free GitHub account today to subscribe to this repository for new releases and build software alongside 28 million developers.Sign up
Scala 2.13 is getting closer and closer!
We've been polishing the improved and simplified Scala collections library that first shipped in 2.13.0-M4. We expect the API to remain stable now, though there may still be minor changes in RC1.
M5 is our feature-freeze release for 2.13. From here forward, we’ll close existing open loops but not embark on or accept new work.
The major collections changes already landed in M4. See the M4 release notes for a summary.
To learn more about those changes and how to adapt your code, take a look at the FAQ wiki page. This document is intended for library maintainers and assumes familiarity with the 2.12 Scala collections. Additional documentation will become available soon.
Here's the biggest additional collections changes since M4:
- The new CHAMP-based
HashSetimplementations are now the default (#7074)
LazyList's empty-or-not status is now lazy too (#7000)
- Variables bound in pattern matches by the
x @ _*syntax are now typed
scala.Seq(immutable); name-based pattern matching has changed to enable this (#7068)
- Arrays passed as varargs are now defensively copied (#6970)
- Offer stronger guarantees under the Java Memory Model for
Iteratorand collection companion objects now have an
- Collections now have
.sizeIsmethods (#6950, #6758)
- Improved support for extension methods on collections via
IsIterableet al (#6674)
- Now deprecated:
.mapValues(#7014), symbolic methods with multiple arguments (#6719)
- Added immutable maps that maintain insertion order (
SeqMap) (#6854), but note that
removemethod was found to be incorrect; the next release will have a fix.
Language and compiler changes
- Compiler output is now deterministic, for reproducible builds (scala-dev#405)
- Support by-name implicits with recursive dictionaries (#6050)
- Better typing for overloaded higher-order methods (#6871)
- Improved compiled times by more aggressively pruning polymorphic implicits during search (#6580)
- Explicit imports now shadow locally defined identifiers (#6589)
- Mixin fields with trait setters are no longer JVM final (#7028)
Library additions and changes
- Updated & revised
scala.util.Using, for automatic resource management (#6907)
Option-returning methods (e.g.
toIntOption) for parsing literals (#6538)
- Case classes and other
Products now have
.withLeftmethods for upcasting the other type parameter (#7011)
pipemethods, for chaining operations, available via
- Added total orderings for
- String-building using
Stringtypes is now deprecated (#6315, #6755)
- Projections on
Eitherare now deprecated (#6682)
implicitNotFoundon parameters (#6340)
Environment and compiler option changes
-Yimportsfor implicit preamble imports (#6764)
- Support JEP 293 style long command-line options (#6499)
- The script runner no longer uses the
fsccompilation daemon by default (#6747)
Compiler performance in 2.13 is 5-10% better compared to 2.12. The integration of the new collections library shows up in the performance graph as a nice improvement.
A big thank you to everyone who's helped improve Scala by reporting bugs, improving our documentation, spreading kindness in discussions around Scala, and submitting and reviewing pull requests! You are all magnificent.
Shout-outs this time to:
- Kenji Yoshida (@xuwei-k), who has contributed to Scala before but in recent months has become ubiquitous in the PR queue
- @NthPortal, Josh Lemer (@joshlemer), A.P. Marki (@som-snytt), and Miles Sabin (@milessabin) for multiple contributions
This release was brought to you by 71 contributors, according to
git shortlog -sn --no-merges ^v2.13.0-M4 v2.13.0-M5. Thank you Jason Zaugg, A. P. Marki, Kenji Yoshida, Stefan Zeiger, NthPortal, Lukas Rytz, Martijn Hoekstra, Allan Renucci, Harrison Houghton, Josh Lemer, Dale Wijnand, exoego, Adriaan Moors, Matthew de Detrich, Miles Sabin, Isaac Levy, Greg Methvin, Julien Richard-Foy, wholock, Eugene Yokota, Seth Tisue, Dan Skells, Guillaume Martres, Georgi Krastev, Aaron S. Hawley, Jasper Moeys, Jonathan Frawley, Diego E. Alonso-Blas, Matthias Sperl, Viktor Klang, Sébastien Doeraene, Marco Zühlke, Mike Skells, Philippus, Chris Phelps, Yuval Dagan, Guillaume Massé, taku0, David Gregory, Yang Bo, Adianto Wibisono, Alejandro Sellero, Alessandro Buggin, Alexey-NM, Bakhytzhan Karabalin, Cong Zhao, Danila Matveev, Diego E. Alonso Blas, Eugene Platonov, Gabriel Claramunt, Georgi Chochov, Ismael Juma, Kamil Duda, Kamil Kloch, Kazuhiro Sera, Mark Petruska, Philippus Baalman, Piotr Kukielka, Robert Stoll, Robin Stephenson, Simão Martins, Sujeet Kausallya Gholap, Vince, jvican, k.bigwheel, naldo, pathikrit, sh0hei, valydia, veera venky, Ólafur Páll Geirsson.
Scala releases are available through a variety of channels, including (but not limited to):
- Bump the
scalaVersionsetting in your sbt-based project
- Download a distribution from scala-lang.org
- Obtain JARs via Maven Central
Libraries for Scala 2.13.0-M5
As libraries are published for M5, they're added to https://github.com/scala/make-release-notes/blob/2.13.x/projects-2.13.md