-
Notifications
You must be signed in to change notification settings - Fork 157
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
The autoRefine macro crashes in the 2.10 REPL #295
Comments
I don't know why, but I can no longer reproduce this issue: $ sbt
...
sbt:refined> ++2.10.6
[info] Setting Scala version to 2.10.6 on 17 projects.
...
sbt:refined> clean
sbt:refined> console
...
[info] Compiling 34 Scala sources to refined/modules/core/jvm/target/scala-2.10/classes ...
[info] Done compiling.
[info] Starting scala interpreter...
...
Welcome to Scala version 2.10.6 (Java HotSpot(TM) 64-Bit Server VM, Java 1.8.0_151).
Type in expressions to have them evaluated.
Type :help for more information.
scala> 1: PosInt
res0: eu.timepit.refined.types.all.PosInt = 1 |
I managed to reproduce this issue on a project where the https://github.com/tek/splain plugin was activated. scalaVersion in ThisBuild := "2.12.4"
libraryDependencies += "eu.timepit" %% "refined" % "0.8.7"
addCompilerPlugin("io.tryp" %% "splain" % "0.2.7" cross CrossVersion.patch)
The ClassCastException only shows up in the scala REPL, the same code compiles just fine when put in a scala file. Everything is back to normal when I remove splain. |
Thanks for the report @vil1. I've no immediate idea what we could do differently in refined to avoid that exception. |
Reported by @vlovgr here: https://gitter.im/fthomas/refined?at=593afdcb7503e2b70629858d
For example
can be reproduced in the 2.10 REPL:
The text was updated successfully, but these errors were encountered: