Skip to content

Commit 6792387

Browse files
committed
add experimental annotation to added type operations and update MiMa
Update MiMaFilters.scala Update MiMaFilters.scala
1 parent f213eff commit 6792387

File tree

7 files changed

+30
-0
lines changed

7 files changed

+30
-0
lines changed

library/src/scala/compiletime/ops/any.scala

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
package scala.compiletime
22
package ops
33

4+
import annotation.experimental
5+
46
object any:
57
/** Equality comparison of two singleton types.
68
* ```scala
@@ -30,6 +32,7 @@ object any:
3032
* ```
3133
* @syntax markdown
3234
*/
35+
@experimental
3336
type IsConst[X] <: Boolean
3437

3538
/** String conversion of a constant singleton type.
@@ -39,4 +42,5 @@ object any:
3942
* ```
4043
* @syntax markdown
4144
*/
45+
@experimental
4246
type ToString[X] <: String

library/src/scala/compiletime/ops/double.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
package scala.compiletime
22
package ops
33

4+
import scala.annotation.experimental
5+
6+
@experimental
47
object double:
58
/** Addition of two `Double` singleton types.
69
* ```scala

library/src/scala/compiletime/ops/float.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
package scala.compiletime
22
package ops
33

4+
import scala.annotation.experimental
5+
6+
@experimental
47
object float:
58
/** Addition of two `Float` singleton types.
69
* ```scala

library/src/scala/compiletime/ops/int.scala

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
package scala.compiletime
22
package ops
33

4+
import annotation.experimental
5+
46
object int:
57
/** Successor of a natural number where zero is the type 0 and successors are reduced as if the definition was
68
*
@@ -190,6 +192,7 @@ object int:
190192
* ```
191193
* @syntax markdown
192194
*/
195+
@experimental
193196
type ToLong[X <: Int] <: Long
194197

195198
/** Float conversion of an `Int` singleton type.
@@ -198,6 +201,7 @@ object int:
198201
* ```
199202
* @syntax markdown
200203
*/
204+
@experimental
201205
type ToFloat[X <: Int] <: Float
202206

203207
/** Double conversion of an `Int` singleton type.
@@ -206,6 +210,7 @@ object int:
206210
* ```
207211
* @syntax markdown
208212
*/
213+
@experimental
209214
type ToDouble[X <: Int] <: Double
210215

211216
/** Number of zero bits preceding the highest-order ("leftmost")
@@ -220,4 +225,5 @@ object int:
220225
* ```
221226
* @syntax markdown
222227
*/
228+
@experimental
223229
type NumberOfLeadingZeros[X <: Int] <: Int

library/src/scala/compiletime/ops/long.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
package scala.compiletime
22
package ops
33

4+
import scala.annotation.experimental
5+
6+
@experimental
47
object long:
58
/** Successor of a natural number where zero is the type 0 and successors are reduced as if the definition was
69
*

library/src/scala/compiletime/ops/string.scala

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
package scala.compiletime
22
package ops
33

4+
import scala.annotation.experimental
5+
46
object string:
57
/** Concatenation of two `String` singleton types.
68
* ```scala
@@ -16,6 +18,7 @@ object string:
1618
* ```
1719
* @syntax markdown
1820
*/
21+
@experimental
1922
type Length[X <: String] <: Int
2023

2124
/** Substring of a `String` singleton type, with a singleton type
@@ -28,6 +31,7 @@ object string:
2831
* ```
2932
* @syntax markdown
3033
*/
34+
@experimental
3135
type Substring[S <: String, IBeg <: Int, IEnd <: Int] <: String
3236

3337
/** Tests if this `String` singleton type matches the given
@@ -37,4 +41,5 @@ object string:
3741
* ```
3842
* @syntax markdown
3943
*/
44+
@experimental
4045
type Matches[S <: String, Regex <: String] <: Boolean

project/MiMaFilters.scala

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,11 @@ object MiMaFilters {
99
ProblemFilters.exclude[DirectMissingMethodProblem]("scala.runtime.Tuples.append"),
1010
ProblemFilters.exclude[ReversedMissingMethodProblem]("scala.quoted.Quotes#reflectModule#TypeReprMethods.substituteTypes"),
1111
ProblemFilters.exclude[DirectMissingMethodProblem]("scala.quoted.Quotes#reflectModule#TypeReprMethods.substituteTypes"),
12+
ProblemFilters.exclude[MissingClassProblem]("scala.compiletime.ops.double"),
13+
ProblemFilters.exclude[MissingClassProblem]("scala.compiletime.ops.double$"),
14+
ProblemFilters.exclude[MissingClassProblem]("scala.compiletime.ops.float"),
15+
ProblemFilters.exclude[MissingClassProblem]("scala.compiletime.ops.float$"),
16+
ProblemFilters.exclude[MissingClassProblem]("scala.compiletime.ops.long"),
17+
ProblemFilters.exclude[MissingClassProblem]("scala.compiletime.ops.long$"),
1218
)
1319
}

0 commit comments

Comments
 (0)