Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
2e81d8b
Add capture checking to boundary and NonLocalReturns
natsukagami Apr 1, 2025
1ada5f6
Add capture-checking test for boundary
natsukagami Mar 11, 2025
0a6490c
Patch DropBreaks to correctly detect boundary blocks
natsukagami Mar 12, 2025
cc82c70
Add capture checking to CommandLineParser
natsukagami Mar 31, 2025
32ef601
Add capture checking to scala.util
natsukagami Mar 31, 2025
28b7705
Add capture checking to scala.runtime
natsukagami Mar 31, 2025
4d88844
Add capture checking to rest of scala.runtime (except TupledFunctions)
natsukagami Apr 1, 2025
8c95d6c
Add capture checking to IArray
natsukagami Aug 7, 2025
9a5c1b7
[TODO INVESTIGATE] IArray: `Array[AnyRef^{xs*}]` not working, revert …
natsukagami Aug 5, 2025
397b62f
Add capture checking to various scala.* base package files
natsukagami Aug 7, 2025
7155f3d
[TODO FIX] Temporarily drop upper bound of higher-kinded type `F` in …
natsukagami Apr 7, 2025
1c7196d
Add capture checking to scala.reflect
natsukagami Apr 7, 2025
67f8eec
[TODO REMOVE] Add TODO list
natsukagami Apr 7, 2025
0791961
[TODO EXPLAIN] Add capture checking to Mirror and TupleMirror
natsukagami Apr 8, 2025
d3ad017
Disable CC on Mirror for now, it's interferring with case classes
natsukagami Aug 11, 2025
11c1aa3
Add capture checking to scala.caps
natsukagami Apr 8, 2025
3b1ca63
Add capture checking to compiletime.Ops
natsukagami Apr 9, 2025
af9d128
Add capture checking to stdLibPatches
natsukagami Apr 9, 2025
e2f2387
Add capture checking to annotations
natsukagami Apr 10, 2025
618ba9c
Attempt to capture-check quotes
natsukagami Apr 10, 2025
2f6a394
Track sun.misc.Unsafe in LazyVal implementation
natsukagami Apr 14, 2025
402ac89
Require Conversion to be pure
natsukagami Jul 31, 2025
ccda5a1
Remove CC from tuples for now, Map is not compiling
natsukagami Aug 7, 2025
d301515
Make sure that DropBreaks catch also constant folded statements
natsukagami Aug 8, 2025
3b957f2
Update test outputs
natsukagami Aug 11, 2025
4f4aa5b
Remove TODO
natsukagami Aug 15, 2025
c771f9f
Remove extra added line
natsukagami Aug 15, 2025
bdfe28a
Apply suggestions from code review
natsukagami Aug 15, 2025
9b0fd11
Update output of boundary test
natsukagami Aug 15, 2025
84bc4e3
Make Break.label public again
natsukagami Aug 16, 2025
78ef541
Add safety comment to `Boundary.label`
natsukagami Aug 16, 2025
6622e4c
Fix boundary test error line number
natsukagami Aug 16, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add capture checking to scala.util
  • Loading branch information
natsukagami committed Aug 15, 2025
commit 32ef601039e2040f55c99477ca6db45ba99ba39a
1 change: 1 addition & 0 deletions library/src/scala/util/FromDigits.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import scala.math.{BigInt}
import quoted.*
import annotation.internal.sharable

import language.experimental.captureChecking

/** A type class for types that admit numeric literals.
*/
Expand Down
2 changes: 2 additions & 0 deletions library/src/scala/util/NotGiven.scala
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package scala.util

import language.experimental.captureChecking

/** A special class used to implement negation in implicit search.
*
* Consider the problem of using implicit `i1` for a query type `D` if an implicit
Expand Down
4 changes: 3 additions & 1 deletion library/src/scala/util/TupledFunction.scala
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package scala.util

import language.experimental.captureChecking

import scala.annotation.implicitNotFound
import scala.annotation.experimental

Expand All @@ -16,7 +18,7 @@ sealed trait TupledFunction[F, G]:

@experimental
private[scala] object TupledFunction:
def apply[F, G](tupledImpl: F => G, untupledImpl: G => F): TupledFunction[F, G] =
def apply[F, G](tupledImpl: F => G, untupledImpl: G => F): TupledFunction[F, G]^{tupledImpl, untupledImpl} =
new TupledFunction[F, G]:
def tupled(f: F): G = tupledImpl(f)
def untupled(g: G): F = untupledImpl(g)
1 change: 1 addition & 0 deletions project/Build.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1083,6 +1083,7 @@ object Build {
// NOTE: Do not use `sourceDirectories` since `sources` are currently pinned until `3.8.0`
"-sourcepath", (Compile / sources).value.map(_.getCanonicalPath).distinct.mkString(File.pathSeparator),
"-Yexplicit-nulls",
"-explain",
),
(Compile / doc / scalacOptions) ++= ScaladocConfigs.DefaultGenerationSettings.value.settings,
(Compile / packageSrc / mappings) ++= {
Expand Down