CodeQL library for C/C++
codeql/cpp-all 0.12.10 (changelog, source)
Search

Member predicate FunctionOutput::isReturnValueDeref

Holds if this is the output value pointed to by the return value of a function, if the function returns a pointer, or the output value referred to by the return value of a function, if the function returns a reference.

Example:

char* getPointer();
float& getReference();
int getInt();
  • isReturnValueDeref(1) holds for the FunctionOutput that represents the value of *getPointer() (with type char).
  • isReturnValueDeref(1) holds for the FunctionOutput that represents the value of getReference() (with type float).
  • There is no FunctionOutput of getInt() for which isReturnValueDeref(_) holds because the return type of getInt() is neither a pointer nor a reference.
predicate isReturnValueDeref(int ind)