diff options
author | Martin Odersky <odersky@gmail.com> | 2017-03-05 11:16:00 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2017-03-05 11:16:00 +0100 |
commit | 9dade983f139922e3389378608face2594d15fd9 (patch) | |
tree | d16c76098cff5950a7cdde0ff6e6111c8a9f57ea /compiler/src/dotty/tools/dotc/reporting/diagnostic | |
parent | 353a4d9f17b91d09dea3c9090c7a21e267372abe (diff) | |
download | dotty-9dade983f139922e3389378608face2594d15fd9.tar.gz dotty-9dade983f139922e3389378608face2594d15fd9.tar.bz2 dotty-9dade983f139922e3389378608face2594d15fd9.zip |
Fixes
(1) Drop unused error message
(2) Drop test which is now illegal
Diffstat (limited to 'compiler/src/dotty/tools/dotc/reporting/diagnostic')
-rw-r--r-- | compiler/src/dotty/tools/dotc/reporting/diagnostic/ErrorMessageID.java | 1 | ||||
-rw-r--r-- | compiler/src/dotty/tools/dotc/reporting/diagnostic/messages.scala | 15 |
2 files changed, 1 insertions, 15 deletions
diff --git a/compiler/src/dotty/tools/dotc/reporting/diagnostic/ErrorMessageID.java b/compiler/src/dotty/tools/dotc/reporting/diagnostic/ErrorMessageID.java index bbd93eb30..a530a937f 100644 --- a/compiler/src/dotty/tools/dotc/reporting/diagnostic/ErrorMessageID.java +++ b/compiler/src/dotty/tools/dotc/reporting/diagnostic/ErrorMessageID.java @@ -32,7 +32,6 @@ public enum ErrorMessageID { ByNameParameterNotSupportedID, WrongNumberOfTypeArgsID, IllegalVariableInPatternAlternativeID, - TypeParamsTypeExpectedID, IdentifierExpectedID, AuxConstructorNeedsNonImplicitParameterID, IncorrectRepeatedParameterSyntaxID, diff --git a/compiler/src/dotty/tools/dotc/reporting/diagnostic/messages.scala b/compiler/src/dotty/tools/dotc/reporting/diagnostic/messages.scala index e367e9ab2..54090074a 100644 --- a/compiler/src/dotty/tools/dotc/reporting/diagnostic/messages.scala +++ b/compiler/src/dotty/tools/dotc/reporting/diagnostic/messages.scala @@ -691,19 +691,6 @@ object messages { } } - case class TypeParamsTypeExpected(mods: untpd.Modifiers, identifier: TermName)(implicit ctx: Context) - extends Message(TypeParamsTypeExpectedID) { - val kind = "Syntax" - val msg = hl"""Expected ${"type"} keyword for type parameter $identifier""" - val explanation = - hl"""|This happens when you add modifiers like ${"private"} or ${"protected"} - |to your type parameter definition without adding the ${"type"} keyword. - | - |Add ${"type"} to your code, e.g.: - |${s"trait A[${mods.flags} type $identifier]"} - |""" - } - case class IdentifierExpected(identifier: String)(implicit ctx: Context) extends Message(IdentifierExpectedID) { val kind = "Syntax" @@ -1138,7 +1125,7 @@ object messages { | |You may want to create an anonymous class extending ${cls.name} with | ${s"class ${cls.name} { }"} - | + | |or add a companion object with | ${s"object ${cls.name} extends ${cls.name}"} | |