Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/dotnet/runtime.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRadek Doulik <radek.doulik@gmail.com>2022-11-11 11:39:50 +0300
committerGitHub <noreply@github.com>2022-11-11 11:39:50 +0300
commite319104de76f2ae04f8ba9957be24e61b04264d8 (patch)
tree1cad565d9872c8cfff463eb8663dad998ed004a1
parentdc2b0f7ca489bf832830aa40f2582b5854890e3f (diff)
Fix Vector<T> != operator (#78177)
-rw-r--r--src/libraries/System.Private.CoreLib/src/System/Numerics/Vector_1.cs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libraries/System.Private.CoreLib/src/System/Numerics/Vector_1.cs b/src/libraries/System.Private.CoreLib/src/System/Numerics/Vector_1.cs
index 05eb1efcafd..960bf249833 100644
--- a/src/libraries/System.Private.CoreLib/src/System/Numerics/Vector_1.cs
+++ b/src/libraries/System.Private.CoreLib/src/System/Numerics/Vector_1.cs
@@ -476,12 +476,12 @@ namespace System.Numerics
{
for (int index = 0; index < Count; index++)
{
- if (Scalar<T>.Equals(left.GetElementUnsafe(index), right.GetElementUnsafe(index)))
+ if (!Scalar<T>.Equals(left.GetElementUnsafe(index), right.GetElementUnsafe(index)))
{
- return false;
+ return true;
}
}
- return true;
+ return false;
}
/// <summary>Shifts each element of a vector left by the specified amount.</summary>