CodeQL library for C#
codeql/csharp-all 0.9.0 (changelog, source)
Search

Module Gvn

INTERNAL: Do not use.

Provides an implementation of Global Value Numbering for types (see https://en.wikipedia.org/wiki/Global_value_numbering), where types are considered equal modulo identity conversions and type parameters.

Import path

import semmle.code.csharp.Unification

Imports

Predicates

getNameNested

Gets the name of type t, including the enclosing type of t as a qualifier, but only if the enclosing type is not a GenericType.

getTypeKind

Gets the type kind for type t, if any.

Classes

CompoundTypeKind

A type kind for a compound type.

ConstructedGvnType
GenericType

A generic type. This is either a type with a type parameter, a type with a type argument, or a nested type with a generic enclosing type.

GvnType

A global value number for a type. Two types have the same GVN when they are structurally equal modulo type parameters and identity conversions. For example, Func<T, int> and Func<S, int> have the same GVN, but Func<T, int> and Func<string, int> do not.

TypeParameterGvnType