Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit c9cb332

Browse files
committed
Fix review comments
1 parent 957113f commit c9cb332

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/mscorlib/shared/System/Numerics/Vector.cs

+1-2
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ public unsafe Vector(T[] values, int index)
390390
}
391391
if (index < 0 || (values.Length - index) < Count)
392392
{
393-
throw new IndexOutOfRangeException();
393+
throw new IndexOutOfRangeException(SR.Format(SR.Arg_InsufficientNumberOfElements, Vector<T>.Count, nameof(values)));
394394
}
395395

396396
if (Vector.IsHardwareAccelerated)
@@ -771,7 +771,6 @@ private Vector(ref Register existingRegister)
771771
/// <summary>
772772
/// Constructs a vector from the given span. The span must contain at least Vector'T.Count elements.
773773
/// </summary>
774-
[Intrinsic]
775774
public unsafe Vector(Span<T> values)
776775
: this()
777776
{

src/mscorlib/shared/System/Numerics/Vector.tt

+1-2
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ namespace System.Numerics
202202
}
203203
if (index < 0 || (values.Length - index) < Count)
204204
{
205-
throw new IndexOutOfRangeException();
205+
throw new IndexOutOfRangeException(SR.Format(SR.Arg_InsufficientNumberOfElements, Vector<T>.Count, nameof(values)));
206206
}
207207

208208
if (Vector.IsHardwareAccelerated)
@@ -291,7 +291,6 @@ namespace System.Numerics
291291
/// <summary>
292292
/// Constructs a vector from the given span. The span must contain at least Vector'T.Count elements.
293293
/// </summary>
294-
[Intrinsic]
295294
public unsafe Vector(Span<T> values)
296295
: this()
297296
{

0 commit comments

Comments
 (0)