diff options
author | Paul Phillips <paulp@improving.org> | 2011-10-14 02:16:17 +0000 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2011-10-14 02:16:17 +0000 |
commit | fcd0998f1e0f2307e9b0cbae6bf2c36234ca8d17 (patch) | |
tree | 3eb2fa53283a9f399cd3e11a15a391b9d0307ca3 /src/compiler/scala/reflect/internal/Symbols.scala | |
parent | bca8959a1ab162dadec51c0db7d062315f5e4d6e (diff) | |
download | scala-fcd0998f1e0f2307e9b0cbae6bf2c36234ca8d17.tar.gz scala-fcd0998f1e0f2307e9b0cbae6bf2c36234ca8d17.tar.bz2 scala-fcd0998f1e0f2307e9b0cbae6bf2c36234ca8d17.zip |
Better error when abstract methods are missing.
When many methods are missing, print a list of signatures the way they
need to be implemented, and throw in ??? stub implementations so it
should be compilable code. If anyone would like this logic exposed more
generally (for the IDE or whatever) just let me know. No review.
Diffstat (limited to 'src/compiler/scala/reflect/internal/Symbols.scala')
-rw-r--r-- | src/compiler/scala/reflect/internal/Symbols.scala | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/compiler/scala/reflect/internal/Symbols.scala b/src/compiler/scala/reflect/internal/Symbols.scala index db17306768..4ded91c16c 100644 --- a/src/compiler/scala/reflect/internal/Symbols.scala +++ b/src/compiler/scala/reflect/internal/Symbols.scala @@ -1900,13 +1900,20 @@ trait Symbols extends api.Symbols { self: SymbolTable => else ExplicitFlags def defaultFlagString = hasFlagsToString(defaultFlagMask) - - /** String representation of symbol's definition */ - def defString = compose( + private def defStringCompose(infoString: String) = compose( defaultFlagString, keyString, - varianceString + nameString + signatureString + varianceString + nameString + infoString ) + /** String representation of symbol's definition. It uses the + * symbol's raw info to avoid forcing types. + */ + def defString = defStringCompose(signatureString) + + /** String representation of symbol's definition, using the supplied + * info rather than the symbol's. + */ + def defStringSeenAs(info: Type) = defStringCompose(infoString(info)) /** Concatenate strings separated by spaces */ private def compose(ss: String*) = ss filter (_ != "") mkString " " |