mirror of
https://github.com/github/codeql.git
synced 2026-02-23 18:33:42 +01:00
Adapt to static methods and nested types returning unbound declaring types
Previously these returned raw declaring types instead
This commit is contained in:
@@ -7,11 +7,11 @@ private import semmle.code.java.dataflow.ExternalFlow
|
||||
|
||||
private class EntryType extends RefType {
|
||||
EntryType() {
|
||||
this.getSourceDeclaration().getASourceSupertype*().hasQualifiedName("java.util", "Map<>$Entry")
|
||||
this.getSourceDeclaration().getASourceSupertype*().hasQualifiedName("java.util", "Map$Entry")
|
||||
}
|
||||
|
||||
RefType getValueType() {
|
||||
exists(GenericType t | t.hasQualifiedName("java.util", "Map<>$Entry") |
|
||||
exists(GenericType t | t.hasQualifiedName("java.util", "Map$Entry") |
|
||||
indirectlyInstantiates(this, t, 1, result)
|
||||
)
|
||||
}
|
||||
@@ -95,10 +95,10 @@ private class ContainerFlowSummaries extends SummaryModelCsv {
|
||||
override predicate row(string row) {
|
||||
row =
|
||||
[
|
||||
"java.util;Map<>$Entry;true;getKey;;;MapKey of Argument[-1];ReturnValue;value",
|
||||
"java.util;Map<>$Entry;true;getValue;;;MapValue of Argument[-1];ReturnValue;value",
|
||||
"java.util;Map<>$Entry;true;setValue;;;MapValue of Argument[-1];ReturnValue;value",
|
||||
"java.util;Map<>$Entry;true;setValue;;;Argument[0];MapValue of Argument[-1];value",
|
||||
"java.util;Map$Entry;true;getKey;;;MapKey of Argument[-1];ReturnValue;value",
|
||||
"java.util;Map$Entry;true;getValue;;;MapValue of Argument[-1];ReturnValue;value",
|
||||
"java.util;Map$Entry;true;setValue;;;MapValue of Argument[-1];ReturnValue;value",
|
||||
"java.util;Map$Entry;true;setValue;;;Argument[0];MapValue of Argument[-1];value",
|
||||
"java.lang;Iterable;true;iterator;();;Element of Argument[-1];Element of ReturnValue;value",
|
||||
"java.lang;Iterable;true;spliterator;();;Element of Argument[-1];Element of ReturnValue;value",
|
||||
"java.util;Iterator;true;next;;;Element of Argument[-1];ReturnValue;value",
|
||||
|
||||
@@ -26,10 +26,10 @@ class PlayMvcHttpRequestHeader extends RefType {
|
||||
}
|
||||
|
||||
/**
|
||||
* A `play.mvc.BodyParser<>$Of` annotation.
|
||||
* A `play.mvc.BodyParser$Of` annotation.
|
||||
*/
|
||||
class PlayBodyParserAnnotation extends Annotation {
|
||||
PlayBodyParserAnnotation() { this.getType().hasQualifiedName("play.mvc", "BodyParser<>$Of") }
|
||||
PlayBodyParserAnnotation() { this.getType().hasQualifiedName("play.mvc", "BodyParser$Of") }
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user