72 references to Hash
Microsoft.CodeAnalysis.Extensions.Package (72)
src\roslyn\src\Compilers\Core\Portable\InternalUtilities\Hash.cs (22)
70hashCode = Hash.Combine(value.GetHashCode(), hashCode); 90hashCode = Hash.Combine(value.GetHashCode(), hashCode); 113hashCode = Hash.Combine(value.GetHashCode(), hashCode); 139hashCode = Hash.Combine(value.GetHashCode(), hashCode); 164hashCode = Hash.Combine(stringComparer.GetHashCode(value), hashCode); 184hashCode = Hash.Combine(stringComparer.GetHashCode(value), hashCode); 210int hashCode = Hash.FnvOffsetBias; 214hashCode = unchecked((hashCode ^ data[i]) * Hash.FnvPrime); 231int hashCode = Hash.FnvOffsetBias; 239hashCode = unchecked((hashCode ^ b) * Hash.FnvPrime); 254int hashCode = Hash.FnvOffsetBias; 258hashCode = unchecked((hashCode ^ data[i]) * Hash.FnvPrime); 274return CombineFNVHash(Hash.FnvOffsetBias, data); 297int hashCode = Hash.FnvOffsetBias; 301hashCode = unchecked((hashCode ^ CaseInsensitiveComparison.ToLower(data[i])) * Hash.FnvPrime); 315return CombineFNVHash(Hash.FnvOffsetBias, text); 326int hashCode = Hash.FnvOffsetBias; 340hashCode = unchecked((hashCode ^ text[i]) * Hash.FnvPrime); 369return Hash.CombineFNVHash(Hash.FnvOffsetBias, ch); 391return unchecked((hashCode ^ ch) * Hash.FnvPrime); 405hashCode = unchecked((hashCode ^ data[i]) * Hash.FnvPrime);
Symbols\SymbolEquivalenceComparer.GetHashCodeVisitor.cs (49)
32_parameterAggregator = (acc, sym) => Hash.Combine(symbolEquivalenceComparer.ParameterEquivalenceComparer.GetHashCode(sym), acc); 50return Hash.Combine(GetNullableAnnotationsHashCode((ITypeSymbol)x), Hash.Combine(typeof(IDynamicTypeSymbol), currentHash)); 84Hash.Combine(GetNullableAnnotationsHashCode(x), 85Hash.Combine(x.Rank, 90=> Hash.Combine(_symbolEquivalenceComparer._assemblyComparer?.GetHashCode(x) ?? 0, currentHash); 95Hash.Combine(x.Name, 102Hash.Combine(x.Name, 103Hash.Combine(x.Locations.FirstOrDefault(), currentHash)); 107=> Hash.Combine(x.Locations.FirstOrDefault(), currentHash); 114currentHash = Hash.Combine(x.MetadataName, currentHash); 117return Hash.Combine(x.Locations.FirstOrDefault(), currentHash); 121Hash.Combine(IsPartialMethodImplementationPart(x), 122Hash.Combine(IsPartialMethodDefinitionPart(x), 123Hash.Combine(x.IsDefinition, 124Hash.Combine(IsConstructedFromSelf(x), 125Hash.Combine(x.Arity, 126Hash.Combine(x.Parameters.Length, 127Hash.Combine(x.Name, currentHash))))))); 144=> CombineHashCodes(x.ContainingAssembly, Hash.Combine(x.Name, currentHash)); 168return Hash.Combine(currentHash, Hash.CombineValues(x.TupleElements)); 174Hash.Combine((int)GetTypeKind(x), 175Hash.Combine(IsConstructedFromSelf(x), 176Hash.Combine(x.Arity, 177Hash.Combine(x.Name, 178Hash.Combine(x.IsAnonymousType, 179Hash.Combine(x.IsUnboundGenericType, 180Hash.Combine(GetNullableAnnotationsHashCode(x), 205return Hash.Combine(p.Name, 206Hash.Combine(p.IsReadOnly, 217return Hash.Combine(x.Name, currentHash); 221Hash.Combine(x.IsGlobalNamespace, 222Hash.Combine(x.Name, 229Hash.Combine(x.IsRefOrOut(), 230Hash.Combine(x.Name, 238Hash.Combine(typeof(IPointerTypeSymbol).GetHashCode(), 245Hash.Combine(x.IsIndexer, 246Hash.Combine(x.Name, 247Hash.Combine(x.Parameters.Length, 248Hash.Combine(IsPartialPropertyImplementationPart(x), 249Hash.Combine(IsPartialPropertyDefinitionPart(x), 258Hash.Combine(x.Name, 259Hash.Combine(IsPartialEventImplementationPart(x), 260Hash.Combine(IsPartialEventDefinitionPart(x), 272Hash.Combine(x.Ordinal, 273Hash.Combine((int)x.TypeParameterKind, currentHash)); 297=> Hash.Combine(x.Locations.FirstOrDefault(), currentHash); 300=> Hash.Combine(x.GetHashCode(), currentHash);
Symbols\SymbolEquivalenceComparer.ParameterSymbolEqualityComparer.cs (1)
69Hash.Combine(x.IsRefOrOut(),