Visual Studio 2019 can generate implementation for GetHashCode. For example the following:
public override int GetHashCode()
{
int hashCode = -1205156623;
hashCode = hashCode * -1521134295 + TotalAllocatedMemorySize.GetHashCode();
hashCode = hashCode * -1521134295 + SurvivedMemorySize.GetHashCode();
return hashCode;
}
Overflowing calculations don’t matter here, as the actual value is not that relevant. I don’t expect S3949 to be raised for this code.