We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b80e1d0 commit f7ad3fdCopy full SHA for f7ad3fd
compiler/src/dotty/tools/dotc/transform/TreeChecker.scala
@@ -413,6 +413,10 @@ class TreeChecker extends Phase with SymTransformer {
413
res
414
}
415
416
+ override def typedSuper(tree: untpd.Super, pt: Type)(using Context): Tree =
417
+ assert(tree.qual.isInstanceOf[untpd.This], i"expect prefix of Super to be This, actual = ${tree.qual}")
418
+ super.typedSuper(tree, pt)
419
+
420
private def checkOwner(tree: untpd.Tree)(using Context): Unit = {
421
def ownerMatches(symOwner: Symbol, ctxOwner: Symbol): Boolean =
422
symOwner == ctxOwner ||
0 commit comments