aboutsummaryrefslogtreecommitdiff
path: root/csharp/src/Google.Protobuf/WellKnownTypes/Wrappers.cs
diff options
context:
space:
mode:
Diffstat (limited to 'csharp/src/Google.Protobuf/WellKnownTypes/Wrappers.cs')
-rw-r--r--csharp/src/Google.Protobuf/WellKnownTypes/Wrappers.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/csharp/src/Google.Protobuf/WellKnownTypes/Wrappers.cs b/csharp/src/Google.Protobuf/WellKnownTypes/Wrappers.cs
index 9a5fb81e..960cfdee 100644
--- a/csharp/src/Google.Protobuf/WellKnownTypes/Wrappers.cs
+++ b/csharp/src/Google.Protobuf/WellKnownTypes/Wrappers.cs
@@ -114,14 +114,14 @@ namespace Google.Protobuf.WellKnownTypes {
if (ReferenceEquals(other, this)) {
return true;
}
- if (Value != other.Value) return false;
+ if (!pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.Equals(Value, other.Value)) return false;
return true;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public override int GetHashCode() {
int hash = 1;
- if (Value != 0D) hash ^= Value.GetHashCode();
+ if (Value != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(Value);
return hash;
}
@@ -239,14 +239,14 @@ namespace Google.Protobuf.WellKnownTypes {
if (ReferenceEquals(other, this)) {
return true;
}
- if (Value != other.Value) return false;
+ if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(Value, other.Value)) return false;
return true;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public override int GetHashCode() {
int hash = 1;
- if (Value != 0F) hash ^= Value.GetHashCode();
+ if (Value != 0F) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(Value);
return hash;
}