diff options
author | Jon Skeet <jonskeet@google.com> | 2015-10-24 06:46:02 +0100 |
---|---|---|
committer | Jon Skeet <jonskeet@google.com> | 2015-10-24 06:46:02 +0100 |
commit | 55313c9c5d7917d58428d84d193ae3772e4684f8 (patch) | |
tree | c3b6e5ed61941b8d165b562d4e4487521c554a8d /csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs | |
parent | 964627ece023577f252b888c9a9d6d9c2c563fc3 (diff) | |
download | protobuf-55313c9c5d7917d58428d84d193ae3772e4684f8.tar.gz protobuf-55313c9c5d7917d58428d84d193ae3772e4684f8.tar.bz2 protobuf-55313c9c5d7917d58428d84d193ae3772e4684f8.zip |
Generated code for previous commit (oneof case contributing to hash code and equality).
Diffstat (limited to 'csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs')
-rw-r--r-- | csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs b/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs index a9961bea..b2d7783c 100644 --- a/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs +++ b/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs @@ -344,6 +344,7 @@ namespace Google.Protobuf.WellKnownTypes { if (BoolValue != other.BoolValue) return false; if (!object.Equals(StructValue, other.StructValue)) return false; if (!object.Equals(ListValue, other.ListValue)) return false; + if (KindCase != other.KindCase) return false; return true; } @@ -355,6 +356,7 @@ namespace Google.Protobuf.WellKnownTypes { if (kindCase_ == KindOneofCase.BoolValue) hash ^= BoolValue.GetHashCode(); if (kindCase_ == KindOneofCase.StructValue) hash ^= StructValue.GetHashCode(); if (kindCase_ == KindOneofCase.ListValue) hash ^= ListValue.GetHashCode(); + hash ^= (int) kindCase_; return hash; } |