Skip to content

Instantly share code, notes, and snippets.

View SethTisue's full-sized avatar

Seth Tisue SethTisue

View GitHub Profile
public <T> boolean exists(scala.collection.Iterable<T>, scala.Function1<T, java.lang.Object>);
0: new #19 // class scala/util/boundary$Label
3: dup
4: invokespecial #44 // Method scala/util/boundary$Label."<init>":()V
7: astore_3
8: aload_1
9: aload_0
10: aload_2
11: aload_3

From scala.xml.pull to

Want to process XML that's too large to fit in memory?

The Scala standard library used to offer scala.xml.pull for this. It became part of the scala-xml library when scala-xml became separate. But then scala.xml.pull got deprecated (in scala.xml 1.1.1) and finally removed entirely (in scala-xml 2.0.0-M1). The recommended replacement is

I had some old code that used scala.xml.pull to digest my iTunes Music Library.xml and print various statistics. Recently I converted it to Scala 3, so I decided to get off the deprecated API at the same time.

So, here is the before-and-after. Perhaps this will help other users of scala.xml.pull who want to convert.

SethTisue /
Last active June 25, 2020 21:06
Scala 2.13.3 draft release notes
SethTisue /
Last active March 11, 2020 10:10
draft release notes for Scala 2.12.11

Collections fixes

  • Fix 2.12-only bug where some toX methods could expose the underlying mutability of a ListBuffer-generated collection (#8674)

(The release includes other collections bugfixes, but this one is especially notable.)

Java interoperability

SethTisue /
Last active September 10, 2019 20:44
Scala 2.12.10 release notes (DRAFT)


The main purpose of this release is to fix the following regressions in 2.12.9:

  • Fix regression in large string interpolations with non-String typed splices (#8315)
  • Revert "Generate shallower ASTs in pattern translation" (#8327, reverting #8061)
  • Fix regression in classpath when JARs have 'a.b' entries beside 'a/b' (#8321)

Further highlights

Fixes with compatibility implications

Scala 2.12.9 generates shallower ASTs in pattern translation, to reduce stack size requirements (-Xss) during compilation.

Scala.js users must update to 0.6.28+ or 1.0.0-M8+ for compatibility with Scala 2.12.9. (#7375)

Highlights of 2.12.9

  • Improved compatibility with JDK 11, 12, and 13 (see below)
SethTisue /
Last active February 19, 2024 00:56
chaining implicit conversions in Scala 2 and Scala 3

in Scala 2, they don't chain 😇, even if we try to give the compiler an assist

can we make them chain in Dotty? 😈

let's try it!

first let's set up sbt:

% cat project/plugins.sbt
SethTisue /
Last active May 17, 2019 13:59
Scala 2.13.0-RC2 draft release notes
SethTisue /
Last active April 5, 2019 13:06
Scala 2.13.0-RC1 draft release notes
SethTisue /
Last active August 28, 2018 02:31
Scala 2.13.0-M5 draft release notes

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.

Collections changes

The major collections changes already landed in M4. See the M4 release notes for a summary.