Skip to content

[do not merge] Add capture checking annotation to Scala 3 Standard Library #23688

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 25 commits into
base: main
Choose a base branch
from

Conversation

natsukagami
Copy link
Contributor

@natsukagami natsukagami commented Aug 7, 2025

List of changes

  • Capture checking enabled for all files except listed in the next section
  • boundary is now capture-checked, preventing Label from being leaked outside of its corresponding boundary. Requires Make caps.Capability non-experimental #23507.
  • `

Files missing capture checking

  • Tuple.scala, waiting for Fix match type bounds checking problem #23695 to reach the next base version
  • Mirror.scala, which requires auto-generated Mirrors to be compatible with extending one of the caps.Capability subtraits. Currently the plan is to simply ban case classes.

@natsukagami natsukagami changed the title Add capture checking annotation to Scala 3 Standard Library [do not merge] Add capture checking annotation to Scala 3 Standard Library Aug 7, 2025
We previously had the `ex.label eq label` comparision, which is no longer the case,
with the (package) private label field.
…tuple match types

Currently it's tripping up the cc phase
Just imports for now, no quotes support for capturing types yet
We need to split the files here, because... ?
@natsukagami natsukagami marked this pull request as ready for review August 14, 2025 14:24
@natsukagami natsukagami requested a review from a team as a code owner August 14, 2025 14:24
@bracevac bracevac self-requested a review August 14, 2025 14:25
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@natsukagami can we please drop this file?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@@ -1149,6 +1149,7 @@ class Definitions {
"reactor.util.annotation.NonNullApi" ::
"io.reactivex.annotations.NonNull" :: Nil)


Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary change here

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file seems to be accidentally included in the PR too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants