mirror of
https://github.com/github/codeql.git
synced 2025-12-18 09:43:15 +01:00
Kotlin: Enable java/misnamed-type query
We used to get alerts for the class around a local function, a lambda, or a function reference, which we give name "". Now those are marked as compiler-generated, and the query ignores compiler-generated types.
This commit is contained in:
@@ -5396,6 +5396,7 @@ open class KotlinFileExtractor(
|
||||
val id = ids.type.javaResult.id.cast<DbClass>()
|
||||
val pkgId = extractPackage("")
|
||||
tw.writeClasses(id, "", pkgId, id)
|
||||
tw.writeCompiler_generated(id, CompilerGeneratedKinds.CALLABLE_CLASS.kind)
|
||||
tw.writeHasLocation(id, locId)
|
||||
|
||||
// Extract constructor
|
||||
@@ -5520,5 +5521,6 @@ open class KotlinFileExtractor(
|
||||
DEFAULT_ARGUMENTS_METHOD(10),
|
||||
INTERFACE_FORWARDER(11),
|
||||
ENUM_CONSTRUCTOR_ARGUMENT(12),
|
||||
CALLABLE_CLASS(13),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user