Skip to content

Commit c75599c

Browse files
committed
C++: Clarify the "most-specific" part of FunctionCall:getTarget
1 parent 70838fe commit c75599c

File tree

1 file changed

+4
-2
lines changed
  • cpp/ql/lib/semmle/code/cpp/exprs

1 file changed

+4
-2
lines changed

cpp/ql/lib/semmle/code/cpp/exprs/Call.qll

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -255,8 +255,10 @@ class FunctionCall extends Call, @funbindexpr {
255255
/**
256256
* Gets the function called by this call.
257257
*
258-
* In the case of virtual function calls, the result is the most-specific function in the override tree (as
259-
* determined by the compiler) such that the target at runtime will be one of `result.getAnOverridingFunction*()`.
258+
* In the case of virtual function calls, the result is the most-specific function in the override tree
259+
* such that the target at runtime will be one of `result.getAnOverridingFunction*()`. The most-specific
260+
* function is determined by the compiler based on the compile time type of the object the function is a
261+
* member of.
260262
*/
261263
override Function getTarget() { funbind(underlyingElement(this), unresolveElement(result)) }
262264

0 commit comments

Comments
 (0)