PostSharp SDK 6.10 / / Class Reference / Post­Sharp.​Sdk.​Code­Model Namespace / IType­Signature Interface / IType­Signature Methods / IType­Signature.​Get­Canonical­Hash­Code Method

ITypeSignature.GetCanonicalHashCode Method

Gets a hash code that is invariant under type signature equality (i.e. if two types are equal under IEquatable<T>, they have the same canonical hash code).

Namespace:  PostSharp.Sdk.CodeModel
Assembly:  PostSharp.Compiler.Engine (in PostSharp.Compiler.Engine.dll) Version: 6.10.14.0 (6.10.14.0)
Syntax
C#
int GetCanonicalHashCode()

Return Value

Type: Int32
A hash code that is invariant under type signature equality.
Remarks
This method is of course useful to build dictionaries. The TypeComparer class uses this method.
See Also