Skip to content

Commit f8366c4

Browse files
WojciechMazurSimY4
authored andcommitted
Remove the Null type bound from CoregexInstances#Matching
1 parent 882dc4c commit f8366c4

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

scalacheck/src/main/scala/com/github/simy4/coregex/scalacheck/CoregexInstances.scala

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,17 @@ import org.scalacheck.{ Arbitrary, Gen, Shrink }
2323
import java.util.regex.Pattern
2424

2525
trait CoregexInstances {
26-
type Matching[A >: Null <: String, Regex >: Null <: String with Singleton] <: A
26+
type Matching[A <: String, Regex <: String with Singleton] <: A
2727

2828
implicit def arbitraryInputStringMatchingRegexStringWithSingleton[
29-
A >: Null <: String,
30-
Regex >: Null <: String with Singleton
29+
A <: String,
30+
Regex <: String with Singleton
3131
](implicit regex: ValueOf[Regex]): Arbitrary[Matching[A, Regex]] =
3232
Arbitrary(CoregexGen.fromPattern(Pattern.compile(regex.value)).asInstanceOf[Gen[Matching[A, Regex]]])
3333

3434
implicit def shrinkInputStringMatchingRegexStringWithSingleton[
35-
A >: Null <: String,
36-
Regex >: Null <: String with Singleton
35+
A <: String,
36+
Regex <: String with Singleton
3737
](implicit regex: ValueOf[Regex]): Shrink[Matching[A, Regex]] = {
3838
val coregex = CoregexParser.getInstance().parse(Pattern.compile(regex.value))
3939
Shrink.withLazyList { larger =>

0 commit comments

Comments
 (0)