Scala 2.13 arrives with collections redesign and additions to the standard library
Scala 2.13 brings a long list of important changes and improvements in several areas with the redesign of collections being at the center of this release. Let’s have a look.
The latest release of Scala is here!
Scala 2.13 arrives with an impressive list of changes and improvements across several key areas.
The most significant change in this release is the redesigning of the collections framework which “provides a common, uniform, and all-encompassing framework for collection types.”
Let’s have a look at the most interesting highlights of the 2.13 release.
Scala 2.13 brings improvements and changes in four key areas: collections, standard library, language, and compiler.
As mentioned earlier, the redesigning of the collections framework is central to this new release.
Most ordinary code that used the old collections will continue to work as it is, except a certain amount of occasion including:
- Simpler method signatures
- Simpler type hierarchy
- Simplified views that work
- New, faster
- New concrete collections
- New abstract collection type
Several additions, changes, as well as deprecations and removals were introduced to the standard library with Scala 2.13. But just to mention a few:
- Integrated Java interop
- new: .
toIntOption, et al
- Library fits in
- Option extends
Deprecations and removals
- String-building using
+with a non-
Stringtype on the left (aka
any2stringadd) is deprecated
- The following modules are no longer included in the distribution: scala-xml, scala-parser-combinators, scala-swing
- Assorted deprecated methods and classes throughout the standard library have been removed entirely
SEE ALSO: Scala: Beyond the basics
Although this release is primarily a library release and not a language/compiler release, there are some noteworthy language changes including some new features, experimental features, and deprecations.
- Literal types
- Partial unification on by default
- By-name implicits with recursive dictionaries
- Underscores in numeric literals
- Macro annotations (experimental)
- Procedure syntax deprecated
- View bounds deprecated
Head over to the official changelog for the extensive list of new features and improvements.