Skip to content

Commit 4e2c8d5

Browse files
committed
Ignore Java constructor call
1 parent 1e77bb8 commit 4e2c8d5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/dotc/transform/init/ParamOverridingCheck.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ object ParamOverridingCheck:
121121
ref.initField(param, value)
122122
printer.println(param.show + " initialized with " + value)
123123

124-
if ctor.hasSource then
124+
if ctor.hasSource && !ctor.is(Flags.JavaDefined) then
125125
val cls = ctor.owner.enclosingClass.asClass
126126
val ddef = ctor.defTree.asInstanceOf[DefDef]
127127
addParamsAsFields(args, thisV, ddef)

0 commit comments

Comments
 (0)