We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6a0b020 commit 91f35a5Copy full SHA for 91f35a5
swift/ql/lib/codeql/swift/elements/decl/MethodDecl.qll
@@ -58,5 +58,10 @@ class MethodDecl extends AbstractFunctionDecl {
58
/**
59
* Holds if this function is a `static` or `class` method, as opposed to an instance method.
60
*/
61
- predicate isStatic() { this.getSelfParam().getType() instanceof MetatypeType }
+ predicate isStaticOrClassMethod() { this.getSelfParam().getType() instanceof MetatypeType }
62
+
63
+ /**
64
+ * Holds if this function is an instance method, as opposed to a `static` or `class` method.
65
+ */
66
+ predicate isInstanceMethod() { not this.isStaticOrClassMethod() }
67
}
0 commit comments