Skip to content
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

fix ImportData.ImportType use of sealed #1211

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions amm/util/src/main/scala/ammonite/util/Imports.scala
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ case class ImportData(fromName: Name,


object ImportData{
sealed case class ImportType(name: String)
val Type = ImportType("Type")
val Term = ImportType("Term")
val TermType = ImportType("TermType")
sealed abstract class ImportType(val name: String) extends Product with Serializable
case object Type extends ImportType("Type")
case object Term extends ImportType("Term")
case object TermType extends ImportType("TermType")

def apply(name: String, importType: ImportType = Term): Seq[ImportData] = {
val elements = name.split('.')
Expand Down