Releases: scala/scala3
Releases Β· scala/scala3
Release list
3.3.8 LTS
Highlights of the release
- Support for JDK 26 #24430
- Multiple coverage improvement to make it on par with Scala 2 support including
// $COVERAGE-OFF$and// $COVERAGE-ON$markers. - New @uncheckedOverride annotation for definitions that may override.
#24545 - Trap Ctrl-C in the REPL: if no command is running clear the prompt, if some
command is running ask for confirmation before exiting.
#24127 - Numerous linting and presentation compiler improvements and fixes.
- New '-Yfuture-lazy-vals' options that allows to compile with new lazy val
implementation compatible with all JDK 9+
#637
Other changes and fixes
Access modifiers
- Check protected parent constructor accesses only occurs in child constructors
#25511 - Fix protected constructor access
#25523
Annotations
- Improve ref check of constructors
#24342 - Also copy param annots at mixin
#24916 - Named arg may be deprecatedName
#21588 - Fix: emit deprecation warnings when a symbol is annotated by a deprecated
annotation #23906 - Fix #20063: Java leading annotation parsing
#25503 - Accommodate adapted Scala 2 annotation value
#17516 - Regression test for #3403 #25521
- Fix: do not allow
@targetNameon primary constructor too
#24682 - Add
@uncheckedOverrideannotation for definitions that may override
#24545
Backend
- Chore: add regression test for #4528
#24663 - Cast inline call results to result type, not method type
#25111 - Regression tests for #25 #25536
- Enforce JVM UTF-8 string limits in the backend
#25300 - Do not simplify isInstanceOf if unrelated types might be subtypes at run-time
#25535 - Adjust purity of trait with lazy member
#23788 - Use
Objects.equalsin translating==
#25314 - Fix generic signatures for mixin forwarders conflicting type parameter names
#24567 - No mixin forwarder when ancestor is sealed
#23482 - Simplify JVM interface list emission, remove a mini-phase
#25203 - Chore: optimize lazy val with power of two
#22428 - Fix infinite loop with bad section ends in TastyHeaderUnpickler
#25676 - Fix TastyPrinter's JAR-walking logic to include subdirectories
#25678
Classpath
- Skip
module-info.classfiles during REPL tab-completion
#24838 - Fix for #22461 Empty ClassPath attribute in one or more classpath jars causes
crash #22462
Coverage
- Make coverage more similar to the one in Scala 2
#23722 - Fix #25555: Preserve singleton precision during scoverage lifting
#25556 - Fixes #25482: Ensure package transformation properly handles language imports
in InstrumentCoverage #25546 - Bugfix: Fix issues with Scala JS and coverage
#24769 - Make coverage support incremental compilation
#24773 - Add support for local coverage on and off with
// $COVERAGE-OFF$and
// $COVERAGE-ON$#24486 - Improvement: Try to optimize coverage phase
#24925 - Scoverage: do not instrument erased values
#25298
Default parameters
- Fix named arguments evaluation order with by-name parameters
#25161
Documentation
- Docs: Enforce links checks in the generated docs
#25425 - Improve the contributing guide
#25384 - Extend copyright into 2026
#24927 - Update README: This is Scala 3
#25424 - Explain implicit vs default args
#25311 - Fix some scaladoc in compiler
#24166 - Docs: fix task name for scaladoc/testOnly
#23678 - Replace internal tab char in comment in Synthesizer.scala
#23691
Enums
- Fix Java enum forwarders to pull from companion on initialization
#24361 - Make enum apply ascriptions inferred types
#25562
Exports
- Fix: look at the underlying of a TermRef for a getter
#24565
Extension Methods
- Accept using right associative parameters
#24766 - Add ctor proxies before exports
#24884 - Fix pkg obj prefix of opaque tp ext meth
#21527 - Better handling of illegal trees in
extension
#25368 - Fix LiftToAnchors for higher-kinded type applications
#23672 - Prevent crash when extension not found
#18830
GADTs
- Also trust TypeTest when there is a Bind
#24568
Implicits
- Only check seen for LazyRef for TypeSizeAccumulator
#20459 - Chore: add regression test for #8581
#24666 - Fix "Regression in zio/zio-schema for typer/implicit resolution"
#24156 - Fix implicit scope liftToAnchors for parameter lower bounds
#23679
Inference
- Tweak type for tryParameterless
#24716
Initialization
- Refine parameter adaptation logic for arrays
#23591
Infrastructure
- Tweak tests to not fail under jdk 25
#25148 - Bump actions/upload-artifact from 6 to 7
#25423 - Bump actions/download-artifact from 7 to 8
#25420 - Bump VirtusLab/scala-cli-setup from 1.12.2 to 1.12.3
#25422 - Bump coursier/cache-action from 7 to 8
#25220 - Bump actions/upload-artifact from 5 to 6
#24758 - Bump actions/download-artifact from 6 to 7
#24759 - Bump actions/checkout from 5 to 6
#24517 - Bump actions/upload-artifact from 4 to 5
#24268 - Bump actions/download-artifact from 5 to 6
#24271 - Bump actions/download-artifact from 4 to 5
#23711 - Bump actions/checkout from 4 to 5
#23710 - Chore: bump sbt to 1.11.5 #23805
- Chore(deps): bump actions/setup-java from 4 to 5
#23812 - Chore: Use numberOfWorkers instead
#24338 - Improvement: Additional way of defining ENABLE_BSP_ALL_PROJECTS
#24122 - Formatting: Format presentation-compiler with scalafmt
#24977 - Ensure mistakes in CI inputs are caught early
#25677
Inline
- Chore: add regression test for #22575
#25337 - Ensure the inline match scrutinee type conforms to the recalculated type
#24988 - Make containsOuterRefsAnywhere follow aliases
#25214 - Find annotation args in inline expansion
#24895 - Chore: add regression test for #10343
#24668 - Improve the test for creating protected method accessors fo...
3.9.0-RC1
Highlights of the release
- Long Term Support
- Make
intotype and modifier stable #26184 - Remove automatic collection of entry points #25215
- Scaladoc: support expectations in snippets #25713
- Restore
Automatic-Module-Namein standard library's manifest #26218
Other changes and fixes
Annotations
- Unify annotation handling for thread-safe & -unsafe lazy vals #24907
Backend
- Use
IndexOutOfBoundsExceptionconstructor withInt#24764 - Emit acceptable Java generic signatures for HKTs #25540
- Unwrap refined types for Java generic signatures #25626
- Fix Java signatures for arrays of value classes #25631
- Fix Java generic signatures for context functions #25632
- Handle HKT bounds in Java generic signatures #25744
- Emit nested module classes as static inner classes #26137
Constructors
- Lambda-owned param ref in ctor incurs no field #23286
Coverage
- Fix #25624: Scoverage and separation checking failures #25625
- Scoverage: do not instrument methods that have too large bodies #25629
- Scoverage & CC interaction: exempt CC nested symbols from @experimental check #25687
- Coverage + Experimental nested match cases interaction fix #25913
- Scoverage: fix broken warnings related to tail recursion and infinite loop detection #25941
- Scoverage: correctly detect curried constructor applications #26048
- Scoverage: correctly lift wildcard and singleton types #26049
- Scoverage: refrain from lifting closures for capture calculus compatibility #26067
- Scoverage: fix lifted type computation for parameterless methods #26069
- Scoverage: Fix coverage parameterless select qualifier casts #26087
Documentation
- Sys, concurrent, runtime (1): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25371
- Collection mutable (2): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25372
- Collection immutable (3): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25373
- Collection core (4): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25374
- Numeric types (5): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25375
- Array, IArray, Predef, Option (6): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25376
- Math (7): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25377
- Quoted, compiletime (8): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25378
- Jdk (9): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25379
- Util, io, ref (10): fill in missing @param, @tparam, and @return tags in Scaladoc comments #25380
- Improve sizeCompare doc #25696
- Function, Tuple, Product (12): fill in missing @param, @tparam, and @return tags in Scaladoc comments (V2) #25996
- Improve Scaladoc for
Tuple#map#26060 - Fixed broken URL links. #26064
- Enable sc:compile for stdlib package scala.annotation #25836
- Enable sc:compile for stdlib package scala.beans #25837
- Enable sc:compile for stdlib package scala.collection #25838
- Enable sc:compile for stdlib package scala.collection.convert #25839
- Fix secondary constructor capture checking #25841
- Enable sc:compile for stdlib package scala.collection.generic #25845
- Enable sc:compile for stdlib package scala.collection.immutable #25855
- Enable sc:compile for stdlib package scala.collection.mutable #25860
- Enable sc:compile for stdlib package scala.collection.compat #25861
- Enable sc:compile for stdlib package scala.compiletime #25862
- Enable sc:compile for stdlib package scala.concurrent #25867
- Enable sc:compile for stdlib package scala.io #25868
- Enable sc:compile for stdlib package scala.jdk #25870
- Enable sc:compile for stdlib package scala.math #25878
- Enable sc:compile for stdlib package scala.quoted #25912
- Enable sc:compile for stdlib package scala.reflect #25915
Enums
- Adjust error on bad enum #23080
- Preserve Java enum semantics for explicit java.lang.Enum inheritance #25658
Erasure
- Preserve erased flags on synthetic context-function parameters #25751
- Fix #24653: Erase aliases of Unit as result type to void. #26192
Expression Compiler
- Fix expression evaluation in debugger under
-old-syntax#26096
Extension Methods
Implicits
- Fixes #24914 Treat equivalent candidates as divergent in implicit search #25910
- Disallow implicit conversion to AnyRef again. #26210
Incremental Compilation
- Support zinc invalidation for type arguments in macro calls #23900
- Ignore annotations no longer on the classpath in ExtractAPI #25889
- Fixes #21383 enable Mode.ReadPositions when reading annotation trees #25911
Inline
Lambda Lift
Linting
- Improve unused check of variable in assignment body #24685
- Warn about dollars in names of definitions unless backticked #24690
- Use precise type for
xincase x @ (_: A, _: B), take 2 #26161
Opaque Types
- Fix crash on invalid opaque type in package #26118
Parser
- Fix span of xml literal #15635
- Warn if name of empty template has trailing colon #23907
- Warn dubious negative literal syntax #24163
- Fix "Compiler crashes when illegal signature of
applyDynamicis used " #24974 - Check ascription in valdef pattern #25597
- Parse Java annotations on wildcard type arguments #26187
Pattern Matching
- Make sealed abstract java classes exhaustive checkable #25788
Pickling
Presentation Compiler
3.8.4
Highlights of the release
- Allow
:helpsyntax for all settings #26052 - feature: Add logical package parsing for sourcepath #25446
- Upgrade Scala CLI to 1.14.0
- https://github.com/VirtusLab/scala-cli/releases/tag/v1.12.5
--crosssupport for run, package and doc sub-commands (experimental)- Global
--offlineconfig key - Local .m2 in publish local (experimental)
- https://github.com/VirtusLab/scala-cli/releases/tag/v1.13.0
- Support for Scala.js 1.21.0
- Ammonite REPL deprecated & scheduled for removal
java-test-runnerfor pure Java tests- GraalVM native-image packaging:
packaging.graalvmJvmIdandpackaging.graalvmArgs
- https://github.com/VirtusLab/scala-cli/releases/tag/v1.14.0
- Support for
.test.java - A toggle to turn auto-IDE-setup off
- Support for
- https://github.com/VirtusLab/scala-cli/releases/tag/v1.12.5
Other changes and fixes
Annotations
- Also copy param annots at mixin #24916
- Named arg may be deprecatedName #21588
- Use
dealiasKeepRefiningAnnotsinAvoidMap#25609
Backend
- Do not simplify isInstanceOf if unrelated types might be subtypes at run-time #25535
- Port more Scala2 tests + some mixin improvements #25573
- Use
Objects.equalsin translating==#25314
Compiler Phases
Context Functions
- Fix crash when processing path dependent context functions using HKTs #25530
Coverage
- Fix #25555: Preserve singleton precision during scoverage lifting #25556
- Fixes #25482: Ensure package transformation properly handles language imports in InstrumentCoverage #25546
- Scoverage: do not instrument erased values. #25298
Default parameters
- Fix named arguments evaluation order with by-name parameters #25161
- Typer: remove by-name lifting and replace default-getter args with fresh syms #25502
Documentation
- Error mentions bad _1 selector #25616
- Document Scala compiler error codes #24734
- Fix capture checking doc links in language.scala #25498
- Docs: apply snippet compiler on new types reference docs #19513
- Remove outdated comment in value classes #25428
- Update
IsIterablescaladoc #24692
Enums
- Make enum apply ascriptions inferred types #25562
Extension Methods
- Accept using right associative parameters #24766
- Better handling of illegal trees in
extension#25368
GADTs
- Also trust TypeTest when there is a Bind #24568
Implicits
- Deprecation when inferring implicit from non-accessible companion #25516
- Fix missing deprecation warning for implicit in non-accessible companion #25608
- Update migration message #25627
Inline
- Ensure the inline match scrutinee type conforms to the recalculated type #24988
- Do not update Symbol defTrees when retyping after Inlining #23870
- Inlines: decide sealing against original target, while using widened type as cast destination #25448
- Do not generate access proxies for locally defined protected defs #25056
- Avoid useless scrutinee proxy vals in inline match reduction #25279
- Improve the test for creating protected method accessors for inlines #25865
Linting
- Match apply in PolyFunction for override #25505
- Value discard checks inline call for exemption #25554
- Introduce error message ids for shadow warnings #25101
- Warn if for with many vals and overloaded map #25090
Match Types
- Restore MatchTypeNoCases warning with correct source position #25470
Named Tuples
- Fix Ycheck crash from singleton tuple selects after specialization #25331
- Fix #23621: make named tuples exhaustive checkable #25267
Nullability
- Patch to allow interop with XMLBuilder and -Yexplicit-nulls #25221
- Be honest about the nullability of ConsoleReporter.reader and SourcePosition.outer. #25561
Opaque Types
- Treat synthetic casts as pure #25126
Overloading
- Pretype args before skipping clause of overloaded application #23012
Parser
- Fix #20063: Java leading annotation parsing #25503
- Observe outdent also for type cases and type blocks in quotes #25519
- Fix: import resolution for Java #25537
- Fix #25456: parser crash on polymorphic context bound #25623
- Accept
primitive.classin annotations #25363 - InCase has indent width of case #25295
- Don't automatically insert OUTDENT before COMMA #25501
- Add "did you mean to use parentheses/a block" when finding a complex expression on the RHS of an infix operator #25099
- Pat var must be isVarPattern #25701
- Don't pop outermost region when skipping #25738
- Context bound always has a span #25809
- Don't lookahead from interpolation #25834
Pattern Matching
- Clean desugaring of simple tuple assignments #25010
- Extend caching in the space engine beyond local context #23483
- Prevent from getting children in case of non-sealed private #25359
- Use MatchCaseUnreachable #24829
- Fix wrong exhaustive check with sequence wildcard on case class with custom unapply #24260
- Try expanding case class to the product of its fields #25454
- Fix false-positive pat mat unreachable case warning #25978
Positions
- Preserve span of
thisduring statification of trait constructors #25354
Presentation Compiler
- Improvement: Add fallbacks in non critical places for presentation compiler #25483
- Improvement: Use method type if it's available #25641
- Bugfix: Fix wrong type in InferredType code action #25469
- Fix & feat: improvements in selection ranges #25290
- Fix: ignore implicit apply for signature help #25294
- Bugfix: remove stale top-level symbols between runs #25317
- feature: Improve the logical sources provider #26079
Quotes
- Fix crashing for context bound type variables in quoted patterns #25286
- Remove redundant mapOver in fixThisTypeModuleClassReferences #25440
- Improve LambdaTypes handling in Quotes reflect memberType #25786
Reflection
- Fix Select.copy in reflect API losing DerivedName for default getters #25269
- Do not expose ClassInfo in memberType in reflect API #24922
Reporting
3.3.8-RC2
Backported fixes
- Backport: Retry backporting #23665
(#910) - Backport "Do not overwrite the supertype of non-trait super in Erasure" to 3.3
LTS (#909) - Backport "feature: Improve the logical sources provider" to 3.3 LTS
(#908) - Backport "feature: Add logical package parsing for sourcepath" to 3.3 LTS
(#907) - Backport "Don't lookahead from interpolation" to 3.3 LTS
(#905) - Backport "Fix infinite loop with bad section ends in TastyHeaderUnpickler" to
3.3 LTS (#904) - Backport "Context bound always has a span" to 3.3 LTS
(#903) - Backport "Parse HTML properly in Scaladoc" to 3.3 LTS
(#902) - Backport "Don't pop outermost region when skipping" to 3.3 LTS
(#901) - Backport "Fix TastyPrinter's JAR-walking logic to include subdirectories" to
3.3 LTS (#900) - Backport "Ensure mistakes in CI inputs are caught early" to 3.3 LTS
(#899) - Backport "Delete dead code in io/Path" to 3.3 LTS
(#898)
Contributors
Thank you to all the contributors who made this release possible π
According to git shortlog -sn --no-merges 3.3.8-RC1..3.3.8-RC2 these are:
16 Tomasz Godzik
2 Solal Pirelli
2 Som Snytt3.8.4-RC3
Backported PRs
- Bump Scala CLI to v1.14.0 (was v1.13.0) #26065
- Bump coursier to 2.1.25-M25 (was 2.1.25-M24) #26057
- Allow
:helpsyntax for all settings #26052 - feature: Improve the logical sources provider #26079
- Add ErrorMessageID to -Winfer-union warnings (#25073) #25249
- Warn if for with many vals and overloaded map #25090
- Recognize Nullable annotations in explicit nulls #25237
- Fix false-positive pat mat unreachable case warning #25978
- Make type arguments to default methods InferredTypeTrees #25852
- Do not overwrite the supertype of non-trait super in Erasure #26081
- Move process parse exceptions to sys.error instead of a custom exception #25675
- Ensure mistakes in CI inputs are caught early #25677
- Fix TastyPrinter's JAR-walking logic to include subdirectories #25678
- Don't pop outermost region when skipping #25738
- Parse HTML properly in Scaladoc #25681
- Context bound always has a span #25809
- Fix infinite loop with bad section ends in TastyHeaderUnpickler #25676
- Don't lookahead from interpolation #25834
Contributors
Thank you to all the contributors who made this release possible π
According to git shortlog -sn --no-merges 3.8.4-RC2..3.8.4-RC3 these are:
8 Solal Pirelli
4 Wojciech Mazur
3 Som Snytt
2 Piotr Chabelski
1 Martin Odersky
1 Tomasz Godzik
3.3.8-RC1
Highlights of the release
- Support for JDK 26 #24430
- Multiple coverage improvement to make it on par with Scala 2 support including
// $COVERAGE-OFF$and// $COVERAGE-ON$markers - New @uncheckedOverride annotation for definitions that may override
#24545 - Trap Ctrl-C in the REPL: if no command is running clear the prompt, if some
command is running ask for confirmation before exiting
#24127 - Numerous linting and presentation compiler improvements and fixes
Other changes and fixes
Access modifiers
- Check protected parent constructor accesses only occurs in child constructors
#25511 - Fix protected constructor access
#25523
Annotations
- Improve ref check of constructors
#24342 - Also copy param annots at mixin
#24916 - Named arg may be deprecatedName
#21588 - Fix: emit deprecation warnings when a symbol is annotated by a deprecated
annotation #23906 - Fix #20063: Java leading annotation parsing
#25503 - Accommodate adapted Scala 2 annotation value
#17516 - Regression test for #3403 #25521
- Fix: do not allow
@targetNameon primary constructor too
#24682 - Add
@uncheckedOverrideannotation for definitions that may override
#24545
Backend
- Chore: add regression test for #4528
#24663 - Cast inline call results to result type, not method type
#25111 - Regression tests for #25 #25536
- Enforce JVM UTF-8 string limits in the backend
#25300 - Do not simplify isInstanceOf if unrelated types might be subtypes at run-time
#25535 - Adjust purity of trait with lazy member
#23788 - Use
Objects.equalsin translating==
#25314 - Fix generic signatures for mixin forwarders conflicting type parameter names
#24567 - No mixin forwarder when ancestor is sealed
#23482 - Simplify JVM interface list emission, remove a mini-phase
#25203 - Chore: optimize lazy val with power of two
#22428
Classpath
- Skip
module-info.classfiles during REPL tab-completion
#24838 - Fix for #22461 Empty ClassPath attribute in one or more classpath jars causes
crash #22462
Coverage
- Make coverage more similar to the one in Scala 2
#23722 - Fix #25555: Preserve singleton precision during scoverage lifting
#25556 - Fixes #25482: Ensure package transformation properly handles language imports
in InstrumentCoverage #25546 - Bugfix: Fix issues with Scala JS and coverage
#24769 - Make coverage support incremental compilation
#24773 - Add support for local coverage on and off with
// $COVERAGE-OFF$and
// $COVERAGE-ON$#24486 - Improvement: Try to optimize coverage phase
#24925 - Scoverage: do not instrument erased values
#25298
Default parameters
- Fix named arguments evaluation order with by-name parameters
#25161
Documentation
- Docs: Enforce links checks in the generated docs
#25425 - Improve the contributing guide
#25384 - Extend copyright into 2026
#24927 - Update README: This is Scala 3
#25424 - Explain implicit vs default args
#25311 - Fix some scaladoc in compiler
#24166 - Docs: fix task name for scaladoc/testOnly
#23678 - Replace internal tab char in comment in Synthesizer.scala
#23691
Enums
- Fix Java enum forwarders to pull from companion on initialization
#24361 - Make enum apply ascriptions inferred types
#25562
Exports
- Fix: look at the underlying of a TermRef for a getter
#24565
Extension Methods
- Accept using right associative parameters
#24766 - Add ctor proxies before exports
#24884 - Fix pkg obj prefix of opaque tp ext meth
#21527 - Better handling of illegal trees in
extension
#25368 - Fix LiftToAnchors for higher-kinded type applications
#23672 - Prevent crash when extension not found
#18830
GADTs
- Also trust TypeTest when there is a Bind
#24568
Implicits
- Only check seen for LazyRef for TypeSizeAccumulator
#20459 - Chore: add regression test for #8581
#24666 - Fix "Regression in zio/zio-schema for typer/implicit resolution"
#24156 - Fix implicit scope liftToAnchors for parameter lower bounds
#23679
Inference
- Tweak type for tryParameterless
#24716
Initialization
- Refine parameter adaptation logic for arrays
#23591
Infrastructure
- Tweak tests to not fail under jdk 25
#25148 - Bump actions/upload-artifact from 6 to 7
#25423 - Bump actions/download-artifact from 7 to 8
#25420 - Bump VirtusLab/scala-cli-setup from 1.12.2 to 1.12.3
#25422 - Bump coursier/cache-action from 7 to 8
#25220 - Bump actions/upload-artifact from 5 to 6
#24758 - Bump actions/download-artifact from 6 to 7
#24759 - Bump actions/checkout from 5 to 6
#24517 - Bump actions/upload-artifact from 4 to 5
#24268 - Bump actions/download-artifact from 5 to 6
#24271 - Bump actions/download-artifact from 4 to 5
#23711 - Bump actions/checkout from 4 to 5
#23710 - Chore: bump sbt to 1.11.5 #23805
- Chore(deps): bump actions/setup-java from 4 to 5
#23812 - Chore: Use numberOfWorkers instead
#24338 - Improvement: Additional way of defining ENABLE_BSP_ALL_PROJECTS
#24122 - Formatting: Format presentation-compiler with scalafmt
#24977
Inline
- Chore: add regression test for #22575
#25337 - Ensure the inline match scrutinee type conforms to the recalculated type
#24988 - Make containsOuterRefsAnywhere follow aliases
#25214 - Find annotation args in inline expansion
#24895 - Chore: add regression test for #10343
#24668 - Improve the test for creating protected method accessors for inlines
#25865 - Do not update Symbol defTrees when retyping after Inlining
#23870 - Prevent opaque types leaking from transparent inline methods
#23792 - Chore: add regression test for #8194
#24655 - Also substitute symbols in case bindings symbols
#24849 - Inlines: decide seali...
3.8.4-RC2
Backported changes
- Revert #24431 #25703
- Bump Scala CLI to v1.13.0 (was v1.12.5) #25810
- Bump
jackson-*to 3.1.2 (was 2.15.1) #25785 - Reject scala.runtime's mutable refs in safe mode #25749
- Tweak SafeRefs allow list for java.util classes #25783
- Tune SafeRefs allow list for scala.util classes #25787
- Require explicit types in assumeSafe definitions in the empty package #25795
- Skip checkSafeAnnots for synthetic symbols #25773
- Reject News with unsupported Java classes #25761
- Improve LambdaTypes handling in Quotes reflect memberType #25786
- Pat var must be isVarPattern #25701
- Do not warn for package object at the top level #25826
- Fix
-Ymagic-offset-headerforDoubleDefinitionerror andimplicitNotFounderrors, and remove global unmanaged cache #25706 - Fix #25691: scalaXml Elem rendering in repl #25781
- Fix Ctrl+C handling in the REPL #25782
- Fix "Scala 3.8.3 compiling covariant overrides with separate compilation causes AbstractMethodError at runtime" #25659
- Fix "Fix Ctrl-C Handling in the REPL" #25835
- Improve the test for creating protected method accessors for inlines #25865
- feature: Add logical package parsing for sourcepath #25446
Contributors
Thank you to all the contributors who made this release possible π
According to git shortlog -sn --no-merges 3.8.4-RC1..3.8.4-RC2 these are:
5 Wojciech Mazur
4 Martin Odersky
4 Piotr Chabelski
3 Matt Bovel
2 Jan Chyb
2 Li Haoyi
2 Solal Pirelli
2 noti0na1
1 Jakub WarchoΕ
1 Som Snytt
1 Tomasz Godzik
1 Yichen Xu
3.8.4-RC1
Highlights of the release
- Bump Scala CLI to 1.12.5 and Coursier to 2.1.25-M24 #25592
Other changes and fixes
Annotations
- Also copy param annots at mixin #24916
- Named arg may be deprecatedName #21588
- Use
dealiasKeepRefiningAnnotsinAvoidMap#25609
Backend
- Do not simplify isInstanceOf if unrelated types might be subtypes at run-time #25535
- Port more Scala2 tests + some mixin improvements #25573
- Use
Objects.equalsin translating==#25314
Compiler Phases
Context Functions
- Fix crash when processing path dependent context functions using HKTs #25530
Coverage
- Fix #25555: Preserve singleton precision during scoverage lifting #25556
- Fixes #25482: Ensure package transformation properly handles language imports in InstrumentCoverage #25546
- Scoverage: do not instrument erased values. #25298
Default parameters
- Fix named arguments evaluation order with by-name parameters #25161
- Typer: remove by-name lifting and replace default-getter args with fresh syms #25502
Documentation
- Error mentions bad _1 selector #25616
- Document Scala compiler error codes #24734
- Fix capture checking doc links in language.scala #25498
- Docs: apply snippet compiler on new types reference docs #19513
- Remove outdated comment in value classes #25428
- Update
IsIterablescaladoc #24692
Enums
- Make enum apply ascriptions inferred types #25562
Experimental: Capture Checking
- Distribute capture set into and-type on RHS of comparison #25509
- Fix global capabilities support in scaladoc #25563
- Improve capture-error precision for lambdas #25583
- Make result types of hoisted superArg defs InferredTypes #25577
- Transform result any to fresh in Setup.transformSym #25584
- Propagate expected types when rechecking match return expressions #25580
- Drop assertion in toFunctionType #25628
- Delay normalization of capture sets of vals and defs #25640
- Fluidify explicit self types for non-CC classes #25639
- Add missing TypeMap in Setup: FreshCapToResult #25648
- Fixes for capture checking case class methods #25278
- Don't add capture variables for type arguments with pure upper bounds #25316
- Two fixes for #25251 #25488
- Fixed #25430: Add missing CaptureChecked flag during ExpandSAMs #25443
- Fix accessibility check for any's in static objects #25582
- Disallow type parameters in OnlyCapability annotations #25496
- Capture check
Try#25072 - Make Capability types have implied capture sets for new #25346
Experimental: Safe Mode
Extension Methods
- Accept using right associative parameters #24766
- Better handling of illegal trees in
extension#25368
GADTs
- Also trust TypeTest when there is a Bind #24568
Implicits
- Deprecation when inferring implicit from non-accessible companion #25516
- Fix missing deprecation warning for implicit in non-accessible companion #25608
- Update migration message #25627
Inline
- Enhance constant-folding during inlining #24431
- Ensure the inline match scrutinee type conforms to the recalculated type #24988
- Do not update Symbol defTrees when retyping after Inlining #23870
- Inlines: decide sealing against original target, while using widened type as cast destination #25448
- Do not generate access proxies for locally defined protected defs #25056
- Avoid useless scrutinee proxy vals in inline match reduction #25279
Linting
- Match apply in PolyFunction for override #25505
- Value discard checks inline call for exemption #25554
- Introduce error message ids for shadow warnings #25101
Match Types
- Restore MatchTypeNoCases warning with correct source position #25470
Named Tuples
- Fix Ycheck crash from singleton tuple selects after specialization #25331
- Fix #23621: make named tuples exhaustive checkable #25267
Nullability
- Patch to allow interop with XMLBuilder and -Yexplicit-nulls #25221
- Be honest about the nullability of ConsoleReporter.reader and SourcePosition.outer. #25561
Opaque Types
- Treat synthetic casts as pure #25126
Overloading
- Pretype args before skipping clause of overloaded application #23012
Parser
- Fix #20063: Java leading annotation parsing #25503
- Observe outdent also for type cases and type blocks in quotes #25519
- Fix: import resolution for Java #25537
- Fix #25456: parser crash on polymorphic context bound #25623
- Accept
primitive.classin annotations #25363 - InCase has indent width of case #25295
- Don't automatically insert OUTDENT before COMMA #25501
- Add "did you mean to use parentheses/a block" when finding a complex expression on the RHS of an infix operator #25099
Pattern Matching
- Clean desugaring of simple tuple assignments #25010
- Extend caching in the space engine beyond local context #23483
- Prevent from getting children in case of non-sealed private #25359
- Use MatchCaseUnreachable #24829
- Fix wrong exhaustive check with sequence wildcard on case class with custom unapply #24260
- Try expanding case class to the product of its fields #25454
Positions
- Preserve span of
thisduring statification of trait constructors #25354
Presentation Compiler
- Improvement: Add fallbacks in non critical places for presentation compiler #25483
- Improvement: Use method type if it's available #25641
- Bugfix: Fix wrong type in InferredType code action #25469
- Fix & feat: improvements in selection ranges #25290
- Fix: ignore implicit apply for signature help #25294
- Bugfix: remove stale top-level symbols between runs #25317
Quotes
3.8.3
Release highlights
- Add support for local coverage on and off with
// $COVERAGE-OFF$and// $COVERAGE-ON$#24486 - Deprecate for removal
-print-linescompiler setting #25330 - Add safe mode capture checking extension #25307
- Port the Scala2 JVM backend optimizer #25165
Other changes and fixes
Desugaring
Documentation
- Fix little errors in the API documentation #25241
- CC Language Reference: Rename
captoany/fresh#25057
Enums
- Deprecate override class, improve checks #24828
- Fix Java enum forwarders to pull from companion on initialization #24361
Experimental: Capture Checking
- Rename caps.cap to caps.any #24923
- Track global capabilities #24883
- Treat local mutable vars as capabilities #24815
- Fix Crashes when Capture-set Parameters Conflict with Terms #25029
- Replace "cannot be included in" by "cannot flow into" in error messages #25155
- CC: Add field captures to self-type constraints #24984
- Add uses clauses for templates #24857
- Drop special code paths for objects #24881
- Do not consider generated getters to be
update def#24906 - Under cc, mark inferred type arguments to inline methods with an
@inferredannotation #25175 - Handle call-by-name types in bad locations under cc #25154
- Fixes for global capabilities #25123
- Warn if reach capability in result will likely cause leakage #24860
- Make
<fluid>decorations replace existing capture sets #25012 - Make TypeMaps in Setup work correctly for
fresh#24985 - For a limited time, also recognize caps.cap #25076
- Fix closure typing #25014
- Map class capture sets via as-seen-from with prefix of created types #24830
- Drop SafeMode attribute in Tasty #25357
- Fix @assumeSafe addition in safe mode #25364
- Disallow @assumeSafe under safe mode #25462
Experimental: Modularity
- Fix nested desugaring of applied constructor types #25288
Exports
- Add ctor proxies before exports #24884
Inline
- Make containsOuterRefsAnywhere follow aliases #25214
- Find annotation args in inline expansion #24895
- Also substitute symbols in case bindings symbols #24849
JDK
JVM Backend
- Simplify JVM interface list emission, remove a mini-phase #25203
- Don't generate bridge methods for inaccessible Java package-private methods #25166
- Revise isLocalToCompilationUnit #24856
- Enforce JVM UTF-8 string limits in the backend #25300
- Fix class super-call invokespecial owner #25437
Linting
- Extension check handles hiBound of opaque type #25172
- Distrust tree pos for patvar lint #25043
- Move second CheckUnused after pattern matcher #25114
- Unused lint ignores args to ctor of enclosing class #24768
- Check inline expansion for exclusion #23019
Metaprogramming
- Fix: Fix incremental compilation of (some unquoted) macros #24969
Named Tuples
- Don't try checking for ambiguous single-element tuples when in types #24910
- Fix "NamedTuple type in match is parsed as named pattern" #24929
- Fix "Named pattern matching doesn't work in
valstatements orforgenerators" #24928 - Fix false exhaustivity warning for pattern returning NamedTuple #23362
Overloading
- Prefer non-extension to extension #24943
Parser
- Check seen for TypeParamRef in TypeSizeAccumulator #25264
- End of new expr never shrinks #25253
- Use
toVectorfor XML literal sequences #23221
Pattern Matching
- Emit unchecked warnings for trait patterns #24962
Presentation Compiler
- Bugfix: inline value false-positive shadowing with lambda params #25140
- Test hover on backticked identifiers with whitespace #25142
- Inlining interpolated variables #25144
- Bugfix: treat self types as parent types #25167
- Feat(pc): add closing labels inlay hints #25178
- Coursier dependency imports should have lexicographic ordering #21592
- Bugfix: Fix various minor presentation compiler issues #25256
- Fix negative activeParameter in signature help #24945
- Closes #7532: Parameter hints not working for functions #23854
- Fix opaque types displayed as
Nothing & Anyin hover and signature help #24921
REPL
- Skip
module-info.classfiles during REPL tab-completion #24838 - Fix REPL usage of macros loaded via
:depand:jar#25312 - Make REPL type echo-ing use partially qualified names where made possible by imports #24850
- Force REPL to not evaluate LazyList #25444
Reporting
- Check -Werror on summarize #25096
- Fixes #24233: Remove misleading JDK compatibility hint for TASTy errors #25171
- Ignore resetting if preferPrevious #24991
- Enhance WInferUnion to not warn propagated explicit union types #25280
- Improve diagnostic message for unnecessary trailing underscore in eta-expansion #25285
- More descriptive "not found" message when type/term exists with the expected term/type name #24959
- Warn on Scala 2 auto-apply if loosely nullary #24811
- Fix printing references to nested objects #25086
- Add error note for type mismatch involving blocks without last expression #25181
- Drop
-print-linesoption #24905 - Don't suggest invisible members of root imports #24999
Runner
Rewrites
- Accommodate ArrowAssoc in infix named arg migration #25255
Scaladoc
3.8.3-RC3
Backported chnages
- Fix issues with Scala JS and the presentation compiler #25550
- Enforce JVM UTF-8 string limits in the backend #25300
- Fix class super-call invokespecial owner #25437
- Port the Scala2 optimizer #25165
Contributors
Thank you to all the contributors who made this release possible π
According to git shortlog -sn --no-merges 3.8.3-RC2..3.8.3-RC3 these are:
49 Solal Pirelli
3 Wojciech Mazur
1 Rikito Taniguchi
1 Tomasz Godzik