summary refs log tree commit diff
path: root/crypto/src/math/ec/LongArray.cs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src/math/ec/LongArray.cs')
-rw-r--r--crypto/src/math/ec/LongArray.cs15
1 files changed, 1 insertions, 14 deletions
diff --git a/crypto/src/math/ec/LongArray.cs b/crypto/src/math/ec/LongArray.cs
index 3475e9ecc..e492f2913 100644
--- a/crypto/src/math/ec/LongArray.cs
+++ b/crypto/src/math/ec/LongArray.cs
@@ -1245,20 +1245,7 @@ namespace Org.BouncyCastle.Math.EC
             return true;
         }
 
-        public override int GetHashCode()
-        {
-            int usedLen = GetUsedLength();
-            int hash = 1;
-            for (int i = 0; i < usedLen; i++)
-            {
-                ulong mi = m_data[i];
-                hash *= 31;
-                hash ^= (int)mi;
-                hash *= 31;
-                hash ^= (int)(mi >> 32);
-            }
-            return hash;
-        }
+        public override int GetHashCode() => Arrays.GetHashCode(m_data, 0, GetUsedLength());
 
         public LongArray Copy()
         {