We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 75d8eea commit 0c8e129Copy full SHA for 0c8e129
compiler/src/dotty/tools/dotc/typer/Checking.scala
@@ -527,7 +527,7 @@ object Checking {
527
fail("Traits cannot have secondary constructors" + addendum)
528
checkApplicable(Inline, sym.isTerm && !sym.isOneOf(Mutable | Module))
529
checkApplicable(Lazy, !sym.isOneOf(Method | Mutable))
530
- if (sym.isType && !sym.is(Deferred))
+ if (sym.isType && !sym.isOneOf(Deferred | JavaDefined))
531
for (cls <- sym.allOverriddenSymbols.filter(_.isClass)) {
532
fail(CannotHaveSameNameAs(sym, cls, CannotHaveSameNameAs.CannotBeOverridden))
533
sym.setFlag(Private) // break the overriding relationship by making sym Private
0 commit comments