CodeQL library for C/C++
Search

Class InParameterDeref

The input value pointed to by a pointer parameter to a function, or the input value referred to by a reference parameter to a function.

Example:

void func(int n, char* p, float& r);
  • There is an InParameterDeref with getIndex() = 1 that represents the value of *p (with type char) on entry to the function.
  • There is an InParameterDeref with getIndex() = 2 that represents the value of r (with type float) on entry to the function.
  • There is no InParameterDeref representing the value of n, because n is neither a pointer nor a reference.

Import path

import cpp

Direct supertypes

Indirect supertypes

Fields

Predicates

getIndex

Gets the zero-based index of the parameter.

isParameterDeref

Holds if this is the input value pointed to by a pointer parameter to a function, or the input value referred to by a reference parameter to a function, where the parameter has index index.

toString

Inherited predicates

isInParameter

Holds if this is the input value of the parameter with index index. DEPRECATED: Use isParameter(index) instead.

from FunctionInput
isInParameterPointer

Holds if this is the input value pointed to by a pointer parameter to a function, or the input value referred to by a reference parameter to a function, where the parameter has index index. DEPRECATED: Use isParameterDeref(index) instead.

from FunctionInput
isInQualifier

Holds if this is the input value pointed to by the this pointer of an instance member function. DEPRECATED: Use isQualifierObject() instead.

from FunctionInput
isParameter

Holds if this is the input value of the parameter with index index.

from FunctionInput
isParameterDerefOrQualifierObject

Holds if i >= 0 and isParameterDeref(i) holds for this value, or if i = -1 and isQualifierObject() holds for this value.

from FunctionInput
isParameterOrQualifierAddress

Holds if i >= 0 and isParameter(i) holds for this value, or if i = -1 and isQualifierAddress() holds for this value.

from FunctionInput
isQualifierAddress

Holds if this is the input value of the this pointer of an instance member function.

from FunctionInput
isQualifierObject

Holds if this is the input value pointed to by the this pointer of an instance member function.

from FunctionInput
isReturnValueDeref

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

from FunctionInput

Charpred