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 313221a commit 799f6e4Copy full SHA for 799f6e4
compiler/src/dotty/tools/dotc/typer/Typer.scala
@@ -2181,7 +2181,7 @@ class Typer extends Namer
2181
private def postProcessInfo(sym: Symbol)(using Context): Unit =
2182
if (!sym.isOneOf(Synthetic | InlineProxy | Param) && sym.info.finalResultType.isRepeatedParam)
2183
report.error(em"Cannot return repeated parameter type ${sym.info.finalResultType}", sym.srcPos)
2184
- if !sym.is(Module) && sym.info.isErasedClass then
+ if !sym.is(Module) && !sym.isConstructor && sym.info.finalResultType.isErasedClass then
2185
sym.setFlag(Erased)
2186
2187
def typedTypeDef(tdef: untpd.TypeDef, sym: Symbol)(using Context): Tree = {
0 commit comments