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

Module IRType

Minimal, language-neutral type system for the IR.

Import path

import semmle.code.cpp.ir.implementation.IRType

Classes

IRAddressType

An address type, representing the memory address of data. Used to represent pointers, references, and lvalues, include those that are garbage collected.

IRBooleanType

A Boolean type, which can hold the values true (non-zero) or false (zero).

IRErrorType

An error type. Used when an error in the source code prevents the extractor from determining the proper type.

IRFloatingPointType

A floating-point type.

IRFunctionAddressType

An address type, representing the memory address of code. Used to represent function pointers, function references, and the target of a direct function call.

IRIntegerType

An integer type. This includes IRSignedIntegerType and IRUnsignedIntegerType.

IRNumericType

A numeric type. This includes IRSignedIntegerType, IRUnsignedIntegerType, and IRFloatingPointType.

IROpaqueType

A type with known size that does not fit any of the other kinds of type. Used to represent classes, structs, unions, fixed-size arrays, pointers-to-member, and more.

IRSignedIntegerType

A signed two’s-complement integer. Also used to represent enums whose underlying type is a signed integer, as well as character types whose representation is signed.

IRType

The language-neutral type of an IR Instruction, Operand, or IRVariable. The interface to IRType and its subclasses is the same across all languages for which the IR is supported, so analyses that expect to be used for multiple languages should generally use IRType rather than a language-specific type.

IRUnknownType

An unknown type. Generally used to represent results and operands that access an unknown set of memory locations, such as the side effects of a function call.

IRUnsignedIntegerType

An unsigned two’s-complement integer. Also used to represent enums whose underlying type is an unsigned integer, as well as character types whose representation is unsigned.

IRVoidType

A void type, which has no values. Used to represent the result type of an instruction that does not produce a result.

Modules

IRTypeConsistency

INTERNAL: Do not use. Query predicates used to check invariants that should hold for all IRType objects. To run all consistency queries for the IR, including the ones below, run “semmle/code/cpp/IR/IRConsistency.ql”.