Closed izzyreal closed 1 year ago
It was intentional in Scala 2 that interpolation used a locally scoped identifier StringContext
, but that behavior was changed, intentionally, in Scala 3.
The above code does not compile in 2.13.10
For the record, the error is "error: Int does not take parameters; signature for interpolation must be StringContext.apply(String*)
"
Thanks for the amendment @SethTisue 👍
What a nice error message from the beginning of the pandemic.
Reproduction steps
Scala version: 2.13.10
Problem
The above code does not compile in 2.13.10 (though it compiles in 3.2.2). If you change the name of the field it compiles in 2.13.10.