Skip to content

Require explicit types in assumeSafe definitions in the empty package#25795

Merged
odersky merged 3 commits into
scala:mainfrom
dotty-staging:assume-safe-emptypkg
Apr 15, 2026
Merged

Require explicit types in assumeSafe definitions in the empty package#25795
odersky merged 3 commits into
scala:mainfrom
dotty-staging:assume-safe-emptypkg

Conversation

@odersky

@odersky odersky commented Apr 15, 2026

Copy link
Copy Markdown
Contributor

Also: Merge the duplications of two isExemptFromExplicitChecks definitions that
diverged with subtle differences.

Based on #25770. Only last commit is new.

noti0na1 added a commit that referenced this pull request Apr 15, 2026
)

See individual commit titles for details what got fixed.

Three main areas of fixes:

- Infrastructure dealing with objects: subsumes rule,
pickling/unpickling of use sets, refinements to pathRoot and pathOwner
- Fixes to recheckIdent: Corrections to what is the proper prefix to
check, also include methods that are not in some enclosing scope in
checks.
- Fixes to explicit checks: Don't exempt definitions in the empty
package if they are compiled in safe mode or wrapped in an
`@assumeSafe`. Merge the diverging definitions of
isExemptFromExplicitChecks in CheckCaptures and CaptureOps. EDIT: These
are now in #25795.

Fixes #25758
odersky added 2 commits April 15, 2026 17:19
Also: Merge the duplications of two isExemptFromExplicitChecks definitions that
diverged with subtle differences.
@odersky odersky force-pushed the assume-safe-emptypkg branch from 814e2bd to ff12817 Compare April 15, 2026 15:20
@odersky odersky merged commit 778e9be into scala:main Apr 15, 2026
45 checks passed
@odersky odersky deleted the assume-safe-emptypkg branch April 15, 2026 18:36
@WojciechMazur WojciechMazur added this to the 3.8.4 milestone Apr 16, 2026
@WojciechMazur WojciechMazur added the backport:nominated If we agree to backport this PR, replace this tag with "backport:accepted", otherwise delete it. label Apr 16, 2026
@WojciechMazur WojciechMazur added backport:accepted This PR needs to be backported, once it's been backported replace this tag by "backport:done" and removed backport:nominated If we agree to backport this PR, replace this tag with "backport:accepted", otherwise delete it. labels Apr 16, 2026
WojciechMazur added a commit that referenced this pull request Apr 16, 2026
…ty package" to 3.8.4 (#25823)

Backports #25795 to the 3.8.4-RC2.

PR submitted by the release tooling.
[skip ci]
@WojciechMazur WojciechMazur added backport:done This PR was successfully backported. and removed backport:accepted This PR needs to be backported, once it's been backported replace this tag by "backport:done" labels Apr 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:done This PR was successfully backported.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants