File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed
compiler/src/dotty/tools/dotc/reporting Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -3671,11 +3671,15 @@ extends Message(ConcreteClassHasUnimplementedMethodsID):
36713671 })
36723672 }
36733673
3674- def msg (using Context ) =
3675- s """ $clazz needs to be abstract, since it has ${missingMethods.size} unimplemented members.
3676- |
3677- | ${renderMissingMethods.mkString(" \n " )}
3678- | """ .stripMargin
3674+ def msg (using Context ) = missingMethods match
3675+ case single :: Nil =>
3676+ def showDclAndLocation (sym : Symbol ) = s " ${sym.showDcl} in ${sym.owner.showLocated}"
3677+ s " $clazz needs to be abstract, since ${showDclAndLocation(single)} is not defined "
3678+ case _ =>
3679+ s """ $clazz needs to be abstract, since it has ${missingMethods.size} unimplemented members.
3680+ |
3681+ | ${renderMissingMethods.mkString(" \n " )}
3682+ | """ .stripMargin
36793683
36803684 def explain (using Context ) = " "
36813685 override def actions (using Context ) = this .actions
You can’t perform that action at this time.
0 commit comments