Skip to content

Commit 75ef17d

Browse files
committed
resets
1 parent 4dc83be commit 75ef17d

File tree

6 files changed

+98
-74
lines changed

6 files changed

+98
-74
lines changed

xml/System.Numerics.Tensors/IReadOnlyTensor`2.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -749,7 +749,7 @@
749749
<returns>The current tensor if it is already dense; otherwise, a new tensor that contains the elements of this tensor.</returns>
750750
<remarks>
751751
<para>A dense tensor is one where the elements are ordered sequentially in memory and where no gaps exist between the elements.</para>
752-
<para>For a 2x2 Tensor, this would mean it has <c>FlattendLength: 4; Lengths: [2, 2]; Strides: [4, 1]</c>. The elements would be sequentially accessed via indexes: <c>[0, 0]; [0, 1]; [1, 0]; [1, 1]</c>.</para>
752+
<para>For a 2x2 Tensor, this would mean it has <c>FlattenedLength: 4; Lengths: [2, 2]; Strides: [4, 1]</c>. The elements would be sequentially accessed via indexes: <c>[0, 0]; [0, 1]; [1, 0]; [1, 1]</c>.</para>
753753
</remarks>
754754
</Docs>
755755
</Member>

xml/System.Numerics.Tensors/ReadOnlyTensorSpan`1.xml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -724,7 +724,6 @@
724724
<param name="destination">To be added.</param>
725725
<summary>To be added.</summary>
726726
<remarks>To be added.</remarks>
727-
<inheritdoc cref="M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@)" />
728727
</Docs>
729728
</Member>
730729
<Member MemberName="Empty">
@@ -1989,7 +1988,7 @@
19891988
<MemberSignature Language="C++ CLI" Value=" virtual void System.Numerics.Tensors.IReadOnlyTensor&lt;System.Numerics.Tensors.ReadOnlyTensorSpan&lt;T&gt;,T&gt;.CopyTo(System::Numerics::Tensors::TensorSpan&lt;T&gt; ^ destination) = System::Numerics::Tensors::IReadOnlyTensor&lt;System::Numerics::Tensors::ReadOnlyTensorSpan&lt;T&gt;, T&gt;::CopyTo;" />
19901989
<MemberType>Method</MemberType>
19911990
<Implements>
1992-
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@)</InterfaceMember>
1991+
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@|System.Runtime.InteropServices.InAttribute)</InterfaceMember>
19931992
</Implements>
19941993
<AssemblyInfo>
19951994
<AssemblyName>System.Numerics.Tensors</AssemblyName>
@@ -2052,7 +2051,7 @@
20522051
<MemberSignature Language="C++ CLI" Value=" virtual bool System.Numerics.Tensors.IReadOnlyTensor&lt;System.Numerics.Tensors.ReadOnlyTensorSpan&lt;T&gt;,T&gt;.TryCopyTo(System::Numerics::Tensors::TensorSpan&lt;T&gt; ^ destination) = System::Numerics::Tensors::IReadOnlyTensor&lt;System::Numerics::Tensors::ReadOnlyTensorSpan&lt;T&gt;, T&gt;::TryCopyTo;" />
20532052
<MemberType>Method</MemberType>
20542053
<Implements>
2055-
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@)</InterfaceMember>
2054+
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@|System.Runtime.InteropServices.InAttribute)</InterfaceMember>
20562055
</Implements>
20572056
<AssemblyInfo>
20582057
<AssemblyName>System.Numerics.Tensors</AssemblyName>
@@ -2189,7 +2188,6 @@
21892188
<summary>To be added.</summary>
21902189
<returns>To be added.</returns>
21912190
<remarks>To be added.</remarks>
2192-
<inheritdoc cref="M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@)" />
21932191
</Docs>
21942192
</Member>
21952193
<Member MemberName="TryFlattenTo">

xml/System.Numerics.Tensors/TensorSpan`1.xml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -863,7 +863,6 @@
863863
<param name="destination">To be added.</param>
864864
<summary>To be added.</summary>
865865
<remarks>To be added.</remarks>
866-
<inheritdoc cref="M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@)" />
867866
</Docs>
868867
</Member>
869868
<Member MemberName="Empty">
@@ -2059,7 +2058,7 @@
20592058
<MemberSignature Language="C++ CLI" Value=" virtual void System.Numerics.Tensors.IReadOnlyTensor&lt;System.Numerics.Tensors.TensorSpan&lt;T&gt;,T&gt;.CopyTo(System::Numerics::Tensors::TensorSpan&lt;T&gt; ^ destination) = System::Numerics::Tensors::IReadOnlyTensor&lt;System::Numerics::Tensors::TensorSpan&lt;T&gt;, T&gt;::CopyTo;" />
20602059
<MemberType>Method</MemberType>
20612060
<Implements>
2062-
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@)</InterfaceMember>
2061+
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@|System.Runtime.InteropServices.InAttribute)</InterfaceMember>
20632062
</Implements>
20642063
<AssemblyInfo>
20652064
<AssemblyName>System.Numerics.Tensors</AssemblyName>
@@ -2353,7 +2352,7 @@
23532352
<MemberSignature Language="C++ CLI" Value=" virtual bool System.Numerics.Tensors.IReadOnlyTensor&lt;System.Numerics.Tensors.TensorSpan&lt;T&gt;,T&gt;.TryCopyTo(System::Numerics::Tensors::TensorSpan&lt;T&gt; ^ destination) = System::Numerics::Tensors::IReadOnlyTensor&lt;System::Numerics::Tensors::TensorSpan&lt;T&gt;, T&gt;::TryCopyTo;" />
23542353
<MemberType>Method</MemberType>
23552354
<Implements>
2356-
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@)</InterfaceMember>
2355+
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@|System.Runtime.InteropServices.InAttribute)</InterfaceMember>
23572356
</Implements>
23582357
<AssemblyInfo>
23592358
<AssemblyName>System.Numerics.Tensors</AssemblyName>
@@ -2939,7 +2938,6 @@
29392938
<summary>To be added.</summary>
29402939
<returns>To be added.</returns>
29412940
<remarks>To be added.</remarks>
2942-
<inheritdoc cref="M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@)" />
29432941
</Docs>
29442942
</Member>
29452943
<Member MemberName="TryFlattenTo">

xml/System.Numerics.Tensors/Tensor`1.xml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -483,7 +483,6 @@
483483
<param name="destination">To be added.</param>
484484
<summary>To be added.</summary>
485485
<remarks>To be added.</remarks>
486-
<inheritdoc cref="M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@)" />
487486
</Docs>
488487
</Member>
489488
<Member MemberName="Empty">
@@ -727,9 +726,7 @@
727726
<Parameters />
728727
<Docs>
729728
<summary>Pins and gets a <see cref="T:System.Buffers.MemoryHandle" /> to the backing memory.</summary>
730-
<returns>
731-
<see cref="T:System.Buffers.MemoryHandle" />
732-
</returns>
729+
<returns>A handle to the backing memory.</returns>
733730
<remarks>To be added.</remarks>
734731
</Docs>
735732
</Member>
@@ -1554,7 +1551,7 @@
15541551
<MemberSignature Language="C++ CLI" Value=" virtual void System.Numerics.Tensors.IReadOnlyTensor&lt;System.Numerics.Tensors.Tensor&lt;T&gt;,T&gt;.CopyTo(System::Numerics::Tensors::TensorSpan&lt;T&gt; ^ destination) = System::Numerics::Tensors::IReadOnlyTensor&lt;System::Numerics::Tensors::Tensor&lt;T&gt; ^, T&gt;::CopyTo;" />
15551552
<MemberType>Method</MemberType>
15561553
<Implements>
1557-
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@)</InterfaceMember>
1554+
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.CopyTo(System.Numerics.Tensors.TensorSpan{`1}@|System.Runtime.InteropServices.InAttribute)</InterfaceMember>
15581555
</Implements>
15591556
<AssemblyInfo>
15601557
<AssemblyName>System.Numerics.Tensors</AssemblyName>
@@ -1836,7 +1833,7 @@
18361833
<MemberSignature Language="C++ CLI" Value=" virtual bool System.Numerics.Tensors.IReadOnlyTensor&lt;System.Numerics.Tensors.Tensor&lt;T&gt;,T&gt;.TryCopyTo(System::Numerics::Tensors::TensorSpan&lt;T&gt; ^ destination) = System::Numerics::Tensors::IReadOnlyTensor&lt;System::Numerics::Tensors::Tensor&lt;T&gt; ^, T&gt;::TryCopyTo;" />
18371834
<MemberType>Method</MemberType>
18381835
<Implements>
1839-
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@)</InterfaceMember>
1836+
<InterfaceMember>M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@|System.Runtime.InteropServices.InAttribute)</InterfaceMember>
18401837
</Implements>
18411838
<AssemblyInfo>
18421839
<AssemblyName>System.Numerics.Tensors</AssemblyName>
@@ -2305,7 +2302,6 @@
23052302
<summary>To be added.</summary>
23062303
<returns>To be added.</returns>
23072304
<remarks>To be added.</remarks>
2308-
<inheritdoc cref="M:System.Numerics.Tensors.IReadOnlyTensor`2.TryCopyTo(System.Numerics.Tensors.TensorSpan{`1}@)" />
23092305
</Docs>
23102306
</Member>
23112307
<Member MemberName="TryFlattenTo">

xml/System/Index.xml

Lines changed: 52 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,21 @@
5454
</Attribute>
5555
</Attributes>
5656
<Docs>
57-
<summary>Represent a type can be used to index a collection either from the start or the end.</summary>
57+
<summary>Represents a type that can be used to index a collection either from the beginning or the end.</summary>
5858
<remarks>
59-
Index is used by the C# compiler to support the new index syntax
60-
<code>
61-
int[] someArray = new int[5] { 1, 2, 3, 4, 5 } ;
62-
int lastElement = someArray[^1]; // lastElement = 5
63-
</code></remarks>
59+
<format type="text/markdown"><![CDATA[
60+
61+
## Remarks
62+
63+
`Index` is used by the C# compiler to support the `^` or ["index from end" operator](/dotnet/csharp/language-reference/operators/member-access-operators#index-from-end-operator-):
64+
65+
```csharp
66+
int[] someArray = new int[5] { 1, 2, 3, 4, 5 };
67+
int lastElement = someArray[^1]; // lastElement = 5
68+
```
69+
70+
]]></format>
71+
</remarks>
6472
</Docs>
6573
<Members>
6674
<Member MemberName=".ctor">
@@ -97,12 +105,19 @@
97105
<Parameter Name="fromEnd" Type="System.Boolean" />
98106
</Parameters>
99107
<Docs>
100-
<param name="value">The index value. it has to be zero or positive number.</param>
101-
<param name="fromEnd">Indicating if the index is from the start or from the end.</param>
102-
<summary>Construct an Index using a value and indicating if the index is from the start or from the end.</summary>
108+
<param name="value">The index value. It has to be greater then or equal to zero.</param>
109+
<param name="fromEnd">
110+
<see langword="true" /> to index from the end of the collection, or <see langword="false" /> to index from the beginning of the collection.</param>
111+
<summary>Initializes a new <see cref="T:System.Index" /> with a specified index position and a value that indicates if the index is from the beginning or the end of a collection.</summary>
103112
<remarks>
104-
If the Index constructed from the end, index value 1 means pointing at the last element and index value 0 means pointing at beyond last element.
105-
</remarks>
113+
<format type="text/markdown"><![CDATA[
114+
115+
## Remarks
116+
117+
If the <xref:System.Index> is constructed from the end, an index value of 1 points to the last element, and an index value of 0 points beyond the last element.
118+
119+
]]></format>
120+
</remarks>
106121
</Docs>
107122
</Member>
108123
<Member MemberName="End">
@@ -139,7 +154,7 @@
139154
<ReturnType>System.Index</ReturnType>
140155
</ReturnValue>
141156
<Docs>
142-
<summary>Create an Index pointing at beyond last element.</summary>
157+
<summary>Gets an <see cref="T:System.Index" /> that points beyond the last element.</summary>
143158
<value>An index that points beyond the last element.</value>
144159
<remarks>To be added.</remarks>
145160
</Docs>
@@ -184,8 +199,8 @@
184199
<Parameter Name="other" Type="System.Index" />
185200
</Parameters>
186201
<Docs>
187-
<param name="other">An object to compare with this object</param>
188-
<summary>Indicates whether the current Index object is equal to another Index object.</summary>
202+
<param name="other">The object to compare with this instance.</param>
203+
<summary>Returns a value that indicates whether the current object is equal to another <see cref="T:System.Index" /> object.</summary>
189204
<returns>
190205
<see langword="true" /> if the current Index object is equal to <paramref name="other" />; <see langword="false" /> otherwise.</returns>
191206
<remarks>To be added.</remarks>
@@ -236,8 +251,8 @@
236251
</Parameter>
237252
</Parameters>
238253
<Docs>
239-
<param name="value">An object to compare with this object</param>
240-
<summary>Indicates whether the current Index object is equal to another object of the same type.</summary>
254+
<param name="value">An object to compare with this instance.</param>
255+
<summary>Indicates whether the current Index object is equal to a specified object.</summary>
241256
<returns>
242257
<see langword="true" /> if <paramref name="value" /> is of type <see cref="T:System.Index" /> and is equal to the current instance; <see langword="false" /> otherwise.</returns>
243258
<remarks>To be added.</remarks>
@@ -280,8 +295,8 @@
280295
<Parameter Name="value" Type="System.Int32" />
281296
</Parameters>
282297
<Docs>
283-
<param name="value">The index value from the end.</param>
284-
<summary>Create an Index from the end at the position indicated by the value.</summary>
298+
<param name="value">The index value from the end of a collection.</param>
299+
<summary>Creates an <see cref="T:System.Index" /> from the end of a collection at a specified index position.</summary>
285300
<returns>The index value.</returns>
286301
<remarks>To be added.</remarks>
287302
</Docs>
@@ -323,8 +338,8 @@
323338
<Parameter Name="value" Type="System.Int32" />
324339
</Parameters>
325340
<Docs>
326-
<param name="value">The index value from the start.</param>
327-
<summary>Create an Index from the start at the position indicated by the value.</summary>
341+
<param name="value">The index position from the start of a collection.</param>
342+
<summary>Creates an <see cref="T:System.Index" /> from the specified index at the start of a collection.</summary>
328343
<returns>The index value.</returns>
329344
<remarks>To be added.</remarks>
330345
</Docs>
@@ -406,15 +421,20 @@
406421
<Parameter Name="length" Type="System.Int32" />
407422
</Parameters>
408423
<Docs>
409-
<param name="length">The length of the collection that the Index will be used with. length has to be a positive value</param>
410-
<summary>Calculate the offset from the start using the giving collection length.</summary>
424+
<param name="length">The length of the collection that the Index will be used with. Must be a positive value.</param>
425+
<summary>Calculates the offset from the start of the collection using the specified collection length.</summary>
411426
<returns>The offset.</returns>
412427
<remarks>
413-
For performance reason, we don't validate the input length parameter and the returned offset value against negative values.
414-
we don't validate either the returned offset is greater than the input length.
415-
It is expected Index will be used with collections which always have non negative length/count. If the returned offset is negative and
416-
then used to index a collection will get out of range exception which will be same affect as the validation.
417-
</remarks>
428+
<format type="text/markdown"><![CDATA[
429+
430+
## Remarks
431+
432+
For performance reasons, this method does not validate if `length` or the returned value are negative. It also doesn't validate if the returned value is greater than `length`.
433+
434+
Collections are not expected to have a negative length/count. If this method's returned offset is negative and is then used to index a collection, the runtime will throw <xref:System.ArgumentOutOfRangeException>, which will have the same effect as validation.
435+
436+
]]></format>
437+
</remarks>
418438
</Docs>
419439
</Member>
420440
<Member MemberName="IsFromEnd">
@@ -451,7 +471,7 @@
451471
<ReturnType>System.Boolean</ReturnType>
452472
</ReturnValue>
453473
<Docs>
454-
<summary>Indicates whether the index is from the start or the end.</summary>
474+
<summary>Gets a value that indicates whether the index is from the start or the end.</summary>
455475
<value>
456476
<see langword="true" /> if the Index is from the end; otherwise, <see langword="false" />.</value>
457477
<remarks>To be added.</remarks>
@@ -495,7 +515,7 @@
495515
</Parameters>
496516
<Docs>
497517
<param name="value">The integer to convert.</param>
498-
<summary>Converts integer number to an Index.</summary>
518+
<summary>Converts an integer number to an <see cref="T:System.Index" />.</summary>
499519
<returns>An index representing the integer.</returns>
500520
<remarks>To be added.</remarks>
501521
</Docs>
@@ -534,7 +554,7 @@
534554
<ReturnType>System.Index</ReturnType>
535555
</ReturnValue>
536556
<Docs>
537-
<summary>Create an Index pointing at first element.</summary>
557+
<summary>Gets an <see cref="T:System.Index" /> that points to the first element of a collection.</summary>
538558
<value>An instance that points to the first element of a collection.</value>
539559
<remarks>To be added.</remarks>
540560
</Docs>
@@ -574,7 +594,7 @@
574594
</ReturnValue>
575595
<Parameters />
576596
<Docs>
577-
<summary>Converts the value of the current Index object to its equivalent string representation.</summary>
597+
<summary>Returns the string representation of the current <see cref="T:System.Index" /> instance.</summary>
578598
<returns>The string representation of the <see cref="T:System.Index" />.</returns>
579599
<remarks>To be added.</remarks>
580600
</Docs>
@@ -613,7 +633,7 @@
613633
<ReturnType>System.Int32</ReturnType>
614634
</ReturnValue>
615635
<Docs>
616-
<summary>Returns the index value.</summary>
636+
<summary>Gets the index value.</summary>
617637
<value>The index value.</value>
618638
<remarks>To be added.</remarks>
619639
</Docs>

0 commit comments

Comments
 (0)