Support new callable reference expressions in UAST
Manually mute the class literal test in apiCheck.kt; support for new class literal expressions is postponed because it's not straightforward to combine both unbound (Type::class) and bound (instance::class) class literals in one UClassLiteralExpression: in Java they're two very different expressions (Type.class and instance.getClass())
This commit is contained in:
@@ -86,7 +86,7 @@ open class ApiDetector : Detector(), UastScanner {
|
||||
}
|
||||
|
||||
override fun visitClassLiteralExpression(node: UClassLiteralExpression): Boolean {
|
||||
val clazz = node.type.resolve(context)
|
||||
val clazz = node.type?.resolve(context)
|
||||
if (clazz != null) {
|
||||
checkVersion(context, node, clazz)
|
||||
}
|
||||
@@ -430,4 +430,4 @@ open class ApiDetector : Detector(), UastScanner {
|
||||
ApiDetector::class.java,
|
||||
Scope.SOURCE_FILE_SCOPE))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user