Skip to content

Provide a nice error message if scala. isn't found #2395

Closed
@DarkDimius

Description

@DarkDimius

We should check that classes from dotty-library and scala-library can be found and report a nice error.

Current error message:

java.lang.Exception
    at dotty.tools.dotc.core.Denotations$MissingRef.<init>(Denotations.scala:1034)
    at dotty.tools.dotc.core.Denotations$MissingRef$.apply(Denotations.scala:1033)
    at dotty.tools.dotc.core.Denotations$DenotationsBase.select$1(Denotations.scala:1183)
creating stub for scala, owner = module class <root>#2, file = null
decls = module sun#3
  module class sun#4
...
bad symbolic reference. A signature
refers to scala[ModuleClass]/T in package <root> which is not available.
It may be completely missing from the current classpath, or the version on
the classpath might be incompatible with the version used when compiling the signature.
Exception in thread "main" java.lang.UnsupportedOperationException: class dotty.tools.dotc.core.Scopes$EmptyScope$.openForMutations
    at dotty.tools.dotc.util.DotClass.unsupported(DotClass.scala:10)
    at dotty.tools.dotc.core.Scopes$Scope.openForMutations(Scopes.scala:161)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions