value YpartialUnification is not a member of scala.tools.nsc.Settings

242 Views Asked by At

I'm trying to run scala cats in REPL. Following cat's instructions I have installed ammonite REPL and put following imports in predef.sc

nterp.configureCompiler(_.settings.YpartialUnification.value = true)
import $ivy.`org.typelevel::cats-core:2.2.0-M1`, cats.implicits._

I got this error when run amm.

predef.sc:1: value YpartialUnification is not a member of scala.tools.nsc.Settings
val res_0 = interp.configureCompiler(_.settings.YpartialUnification.value = true)
                                                ^
Compilation Failed
1

There are 1 best solutions below

0
On BEST ANSWER

In Scala 2.13 partial unification is enabled by default and -Ypartial-unification flag has been removed by Partial unification unconditional; deprecate -Xexperimental #6309

Partial unification is now enabled unless -Xsource:2.12 is specified. The -Ypartial-unification flag has been removed and the -Xexperimental option, which is now redundant, has been deprecated.

thus the compiler no longer accepts -Ypartial-unification.