Skip to content

Commit fb77613

Browse files
authored
Fixed searching for inherited ambiguous methods (#1634)
1 parent 21db05f commit fb77613

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

utbot-framework/src/main/kotlin/org/utbot/framework/codegen/tree/ConstructorUtils.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,8 +342,9 @@ internal fun ClassId.getAmbiguousOverloadsOf(executableId: ExecutableId): Sequen
342342
is ConstructorId -> allConstructors
343343
}
344344

345+
// We should take here not only declared methods but also inherited
345346
return allExecutables.filter {
346-
it.name == executableId.name && it.parameters.size == executableId.executable.parameters.size && it.classId == executableId.classId
347+
it.name == executableId.name && it.parameters.size == executableId.executable.parameters.size
347348
}
348349
}
349350

0 commit comments

Comments
 (0)