Ruby: Move UnknownMethodCall to ast/Call.qll

This commit is contained in:
Harry Maclean
2022-02-04 17:19:18 +13:00
parent a397c65d36
commit eb4f333c25
6 changed files with 11 additions and 12 deletions

View File

@@ -116,6 +116,16 @@ class MethodCall extends Call instanceof MethodCallImpl {
}
}
/**
* A `Method` call that has no known target.
* These will typically be calls to methods inherited from a superclass.
* TODO: When API Graphs is able to resolve calls to methods like `Kernel.send`
* this class is no longer necessary and should be removed.
*/
class UnknownMethodCall extends MethodCall {
UnknownMethodCall() { not exists(this.(Call).getATarget()) }
}
/**
* A call to a setter method.
* ```rb

View File

@@ -8,14 +8,6 @@ import core.Module
import core.Array
import core.Regexp
/**
* A `Method` call that has no known target.
* These will typically be calls to methods inherited from a superclass.
*/
class UnknownMethodCall extends MethodCall {
UnknownMethodCall() { not exists(this.(Call).getATarget()) }
}
/**
* A system command executed via subshell literal syntax.
* E.g.

View File

@@ -1,7 +1,6 @@
private import codeql.ruby.AST
private import codeql.ruby.Concepts
private import codeql.ruby.DataFlow
private import codeql.ruby.frameworks.Core
module BasicObject {
/**

View File

@@ -5,7 +5,6 @@ private import codeql.ruby.Concepts
private import codeql.ruby.DataFlow
private import codeql.ruby.dataflow.FlowSummary
private import codeql.ruby.dataflow.internal.DataFlowDispatch
private import codeql.ruby.frameworks.Core
/** Modeling for the `Kernel` class. */
module Kernel {

View File

@@ -1,7 +1,6 @@
private import codeql.ruby.AST
private import codeql.ruby.Concepts
private import codeql.ruby.DataFlow
private import codeql.ruby.frameworks.Core
module Module {
/**

View File

@@ -1,4 +1,4 @@
private import codeql.ruby.frameworks.Core
private import codeql.ruby.AST
module Object {
/**