зеркало из https://github.com/github/codeql.git
Merge pull request #10331 from igfoo/igfoo/extractConstructorCall3
Kotlin: Remove a cast from extractConstructorCall
This commit is contained in:
Коммит
bf6e988fcd
|
@ -2394,7 +2394,11 @@ open class KotlinFileExtractor(
|
|||
if (e.typeArgumentsCount > 0) {
|
||||
logger.warnElement("Unexpected type arguments (${e.typeArgumentsCount}) for anonymous class constructor call", e)
|
||||
}
|
||||
val c = eType.classifier.owner as IrClass
|
||||
val c = eType.classifier.owner
|
||||
if (c !is IrClass) {
|
||||
logger.errorElement("Anonymous constructor call type not a class (${c.javaClass})", e)
|
||||
return
|
||||
}
|
||||
useAnonymousClass(c)
|
||||
} else {
|
||||
useType(eType)
|
||||
|
|
Загрузка…
Ссылка в новой задаче