Skip to content

Class-based REPL does not support defining value classes #9910

@scabug

Description

@scabug

Classes extending AnyVal cannot be defined in a REPL started with the -Yrepl-class-based option.

E.g.

scala> case class Foo(x: Int) extends AnyVal
error: value class may not be a member of another class
       case class Foo(x: Int) extends AnyVal
                  ^

without the -Yrepl-class-based option, everything works as expected.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions