-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Labels
area:desugarDesugaring happens after parsing but before typing, see desugar.scalaDesugaring happens after parsing but before typing, see desugar.scalaitype:bugprio:highstat:needs spec
Milestone
Description
Generic numeric literals should be under some sort of flag by 3.0 release.
Additionally, the scala.util.FromDigits
classes should probably be moved to some experimental package or external library
Minimized code
this can be done in 3.0.0-M1
nightlies
case class FooNum(toInt: Int)
given util.FromDigits[FooNum]:
def fromDigits(digits: String): FooNum = FooNum(BigInt(digits).toInt)
@main def Test =
val foo: FooNum = 23
println(foo)
Output
FooNum(23)
Expectation
should not compile without a flag
Metadata
Metadata
Assignees
Labels
area:desugarDesugaring happens after parsing but before typing, see desugar.scalaDesugaring happens after parsing but before typing, see desugar.scalaitype:bugprio:highstat:needs spec