summaryrefslogtreecommitdiff
path: root/src/reflect/scala/reflect/internal/pickling/UnPickler.scala
diff options
context:
space:
mode:
authorJason Zaugg <jzaugg@gmail.com>2012-11-10 21:30:00 +0100
committerJason Zaugg <jzaugg@gmail.com>2012-11-10 23:42:57 +0100
commit86e045e2863b04bf4af4abb5c2ce345bcdae2b80 (patch)
treed307c1f495e4ac3dc5d77a4ff8872a2561acd265 /src/reflect/scala/reflect/internal/pickling/UnPickler.scala
parent0b59b4627a76d99531a51c7f17bbfa8b9c8c4bd8 (diff)
downloadscala-86e045e2863b04bf4af4abb5c2ce345bcdae2b80.tar.gz
scala-86e045e2863b04bf4af4abb5c2ce345bcdae2b80.tar.bz2
scala-86e045e2863b04bf4af4abb5c2ce345bcdae2b80.zip
Refine the message and triggering of MissingRequirementError.
- To force a failure of the stub, call a new method `failIfStub` rather than `info`. - Offer a broader range of potential root causes in the error message.
Diffstat (limited to 'src/reflect/scala/reflect/internal/pickling/UnPickler.scala')
-rw-r--r--src/reflect/scala/reflect/internal/pickling/UnPickler.scala8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/reflect/scala/reflect/internal/pickling/UnPickler.scala b/src/reflect/scala/reflect/internal/pickling/UnPickler.scala
index 15465f919a..5464a68205 100644
--- a/src/reflect/scala/reflect/internal/pickling/UnPickler.scala
+++ b/src/reflect/scala/reflect/internal/pickling/UnPickler.scala
@@ -20,7 +20,7 @@ import scala.annotation.switch
/** @author Martin Odersky
* @version 1.0
*/
-abstract class UnPickler /*extends scala.reflect.generic.UnPickler*/ {
+abstract class UnPickler {
val global: SymbolTable
import global._
@@ -233,7 +233,11 @@ abstract class UnPickler /*extends scala.reflect.generic.UnPickler*/ {
// (4) Call the mirror's "missing" hook.
adjust(mirrorThatLoaded(owner).missingHook(owner, name)) orElse {
// (5) Create a stub symbol to defer hard failure a little longer.
- val missingMessage = s"A signature in $filename refers to ${name.longString} in ${owner.fullLocationString} which is missing from the classpath."
+ val missingMessage =
+ s"""|A signature in $filename refers to ${name.longString} in ${owner.fullLocationString}
+ |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 $filename.""".stripMargin
owner.newStubSymbol(name, missingMessage)
}
}