Skip to content

Commit 0270194

Browse files
committed
From review (tx @bartelink!), improve doc and tooltip comments
1 parent 9afabc6 commit 0270194

File tree

1 file changed

+29
-31
lines changed

1 file changed

+29
-31
lines changed

src/FSharp.Control.TaskSeq/TaskSeq.fsi

Lines changed: 29 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ module TaskSeq =
1313
/// Creates a <see cref="taskSeq" /> sequence from <paramref name="source" /> that generates a single element and then ends.
1414
/// </summary>
1515
///
16-
/// <param name="value">The input item to use as the single value for the task sequence.</param>
16+
/// <param name="value">The input item to use as the single item of the task sequence.</param>
1717
val singleton: value: 'T -> taskSeq<'T>
1818

1919
/// <summary>
@@ -35,11 +35,11 @@ module TaskSeq =
3535

3636
/// <summary>
3737
/// Returns the length of the sequence, or <paramref name="max" />, whichever comes first. This operation requires the task sequence
38-
/// to be evaluated in full, or until <paramref name="max" /> items have been processed. Use this method instead of
39-
/// <see cref="TaskSeq.length" /> if you want to prevent too many items to be evaluated, or if the sequence is potentially infinite.
38+
/// to be evaluated ether in full, or until <paramref name="max" /> items have been processed. Use this method instead of
39+
/// <see cref="TaskSeq.length" /> if you need to limit the number of items evaluated, or if the sequence is potentially infinite.
4040
/// </summary>
4141
///
42-
/// <param name="max">The maximum value to return and the maximum items to count.</param>
42+
/// <param name="max">Limit at which to stop evaluating source items for finding the length.</param>
4343
/// <param name="source">The input task sequence.</param>
4444
/// <exception cref="T:ArgumentNullException">Thrown when the input task sequence is null.</exception>
4545
val lengthOrMax: max: int -> source: taskSeq<'T> -> Task<int>
@@ -76,7 +76,7 @@ module TaskSeq =
7676

7777
/// <summary>
7878
/// Generates a new task sequence which, when iterated, will return successive elements by calling the given function
79-
/// with the current index, up to the given count. Each element is saved after its initialization for successive access to
79+
/// with the curren zero-basedt index, up to the given count. Each element is saved after its initialization for successive access to
8080
/// <see cref="IAsyncEnumerator.Current" />, which will not re-evaluate the <paramref name="initializer" />. However,
8181
/// re-iterating the returned task sequence will re-evaluate the initialization function. The returned sequence may
8282
/// be passed between threads safely. However, individual IEnumerator values generated from the returned sequence should
@@ -91,7 +91,7 @@ module TaskSeq =
9191

9292
/// <summary>
9393
/// Generates a new task sequence which, when iterated, will return successive elements by calling the given function
94-
/// with the current index, up to the given count. Each element is saved after its initialization for successive access to
94+
/// with the current zero-based index, up to the given count. Each element is saved after its initialization for successive access to
9595
/// <see cref="IAsyncEnumerator.Current" />, which will not re-evaluate the <paramref name="initializer" />. However,
9696
/// re-iterating the returned task sequence will re-evaluate the initialization function. The returned sequence may
9797
/// be passed between threads safely. However, individual IEnumerator values generated from the returned sequence should
@@ -106,7 +106,7 @@ module TaskSeq =
106106

107107
/// <summary>
108108
/// Generates a new task sequence which, when iterated, will return successive elements by calling the given function
109-
/// with the current index, ad infinitum, or until <see cref="Int32.MaxValue" /> is reached.
109+
/// with the current zero-based index, ad infinitum, or until <see cref="Int32.MaxValue" /> is reached.
110110
/// Each element is saved after its initialization for successive access to
111111
/// <see cref="IAsyncEnumerator.Current" />, which will not re-evaluate the <paramref name="initializer" />. However,
112112
/// re-iterating the returned task sequence will re-evaluate the initialization function. The returned sequence may
@@ -120,7 +120,7 @@ module TaskSeq =
120120

121121
/// <summary>
122122
/// Generates a new task sequence which, when iterated, will return successive elements by calling the given function
123-
/// with the current index, ad infinitum, or until <see cref="Int32.MaxValue" /> is reached.
123+
/// with the current zero-based index, ad infinitum, or until <see cref="Int32.MaxValue" /> is reached.
124124
/// Each element is saved after its initialization for successive access to
125125
/// <see cref="IAsyncEnumerator.Current" />, which will not re-evaluate the <paramref name="initializer" />. However,
126126
/// re-iterating the returned task sequence will re-evaluate the initialization function. The returned sequence may
@@ -208,7 +208,7 @@ module TaskSeq =
208208
val toSeq: source: taskSeq<'T> -> seq<'T>
209209

210210
/// <summary>
211-
/// Builds an <see cref="array" /> asynchronously from the input task sequence in <paramref name="source" />.
211+
/// Builds an <see cref="array" /> asynchronously from the input task sequence.
212212
/// This function is non-blocking while it builds the array.
213213
/// </summary>
214214
///
@@ -218,7 +218,7 @@ module TaskSeq =
218218
val toArrayAsync: source: taskSeq<'T> -> Task<'T[]>
219219

220220
/// <summary>
221-
/// Builds an F# <see cref="list" /> asynchronously from the input task sequence in <paramref name="source" />.
221+
/// Builds an F# <see cref="list" /> asynchronously from the input task sequence.
222222
/// This function is non-blocking while it builds the list.
223223
/// </summary>
224224
///
@@ -228,7 +228,7 @@ module TaskSeq =
228228
val toListAsync: source: taskSeq<'T> -> Task<'T list>
229229

230230
/// <summary>
231-
/// Builds a resizable array asynchronously from the input task sequence in <paramref name="source" />.
231+
/// Gathers items into a ResizeArray (see <see cref="T:System.Collections.Generic.List&lt;_>" />) asynchronously from the input task sequence.
232232
/// This function is non-blocking while it builds the resizable array.
233233
/// </summary>
234234
///
@@ -238,7 +238,7 @@ module TaskSeq =
238238
val toResizeArrayAsync: source: taskSeq<'T> -> Task<ResizeArray<'T>>
239239

240240
/// <summary>
241-
/// Builds an <see cref="IList&lt;'T>" /> asynchronously from the input task sequence in <paramref name="source" />.
241+
/// Builds an <see cref="IList&lt;'T>" /> asynchronously from the input task sequence.
242242
/// This function is non-blocking while it builds the IList.
243243
/// </summary>
244244
///
@@ -404,7 +404,7 @@ module TaskSeq =
404404

405405
/// <summary>
406406
/// Iterates over the input task sequence, applying the <paramref name="action" /> function to each item,
407-
/// carrying the index as extra parameter for the <paramref name="action" /> function.
407+
/// supplying the zero-based index as extra parameter for the <paramref name="action" /> function.
408408
/// This function is non-blocking, but will exhaust the full input sequence as soon as the task is evaluated.
409409
/// </summary>
410410
///
@@ -427,7 +427,7 @@ module TaskSeq =
427427

428428
/// <summary>
429429
/// Iterates over the input task sequence, applying the asynchronous <paramref name="action" /> function to each item,
430-
/// carrying the index as extra parameter for the <paramref name="action" /> function.
430+
/// supplying the zero-based index as extra parameter for the <paramref name="action" /> function.
431431
/// This function is non-blocking, but will exhaust the full input sequence as soon as the task is evaluated.
432432
/// </summary>
433433
///
@@ -451,7 +451,7 @@ module TaskSeq =
451451
/// <summary>
452452
/// Builds a new task sequence whose elements are the results of applying the <paramref name="action" />
453453
/// function to each of the elements of the input task sequence in <paramref name="source" />.
454-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
454+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
455455
/// method on async enumerators retrieved from the input task sequence.
456456
/// Does not evaluate the input sequence until requested.
457457
/// </summary>
@@ -465,8 +465,8 @@ module TaskSeq =
465465
/// <summary>
466466
/// Builds a new task sequence whose elements are the results of applying the <paramref name="action" />
467467
/// function to each of the elements of the input task sequence in <paramref name="source" />, passing
468-
/// an extra index argument to the <paramref name="action" /> function.
469-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
468+
/// an extra zero-based index argument to the <paramref name="action" /> function.
469+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
470470
/// method on async enumerators retrieved from the input task sequence.
471471
/// Does not evaluate the input sequence until requested.
472472
/// </summary>
@@ -480,7 +480,7 @@ module TaskSeq =
480480
/// <summary>
481481
/// Builds a new task sequence whose elements are the results of applying the asynchronous <paramref name="action" />
482482
/// function to each of the elements of the input task sequence in <paramref name="source" />.
483-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
483+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
484484
/// method on async enumerators retrieved from the input task sequence.
485485
/// Does not evaluate the input sequence until requested.
486486
/// </summary>
@@ -494,8 +494,8 @@ module TaskSeq =
494494
/// <summary>
495495
/// Builds a new task sequence whose elements are the results of applying the asynchronous <paramref name="action" />
496496
/// function to each of the elements of the input task sequence in <paramref name="source" />, passing
497-
/// an extra index argument to the <paramref name="action" /> function.
498-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
497+
/// an extra zero-based index argument to the <paramref name="action" /> function.
498+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
499499
/// method on async enumerators retrieved from the input task sequence.
500500
/// Does not evaluate the input sequence until requested.
501501
/// </summary>
@@ -510,7 +510,7 @@ module TaskSeq =
510510
/// Builds a new task sequence whose elements are the results of applying the <paramref name="binder" />
511511
/// function to each of the elements of the input task sequence in <paramref name="source" />, and concatenating the
512512
/// returned task sequences.
513-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
513+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
514514
/// method on async enumerators retrieved from the input task sequence.
515515
/// Does not evaluate the input sequence until requested.
516516
/// </summary>
@@ -525,7 +525,7 @@ module TaskSeq =
525525
/// Builds a new task sequence whose elements are the results of applying the <paramref name="binder" />
526526
/// function to each of the elements of the input task sequence in <paramref name="source" />, and concatenating the
527527
/// returned regular F# sequences.
528-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
528+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
529529
/// method on async enumerators retrieved from the input task sequence.
530530
/// Does not evaluate the input sequence until requested.
531531
/// </summary>
@@ -540,7 +540,7 @@ module TaskSeq =
540540
/// Builds a new task sequence whose elements are the results of applying the asynchronous <paramref name="binder" />
541541
/// function to each of the elements of the input task sequence in <paramref name="source" />, and concatenating the
542542
/// returned task sequences.
543-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
543+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
544544
/// method on async enumerators retrieved from the input task sequence.
545545
/// Does not evaluate the input sequence until requested.
546546
/// </summary>
@@ -555,7 +555,7 @@ module TaskSeq =
555555
/// Builds a new task sequence whose elements are the results of applying the asynchronous <paramref name="binder" />
556556
/// function to each of the elements of the input task sequence in <paramref name="source" />, and concatenating the
557557
/// returned regular F# sequences.
558-
/// The given function will be applied as elements are demanded using the <see cref="MoveNextAsync" />
558+
/// The given function will be applied as elements are pulled using the <see cref="MoveNextAsync" />
559559
/// method on async enumerators retrieved from the input task sequence.
560560
/// Does not evaluate the input sequence until requested.
561561
/// </summary>
@@ -577,7 +577,7 @@ module TaskSeq =
577577
val tryHead: source: taskSeq<'T> -> Task<'T option>
578578

579579
/// <summary>
580-
/// Returns the first elementof the input task sequence given by <paramref name="source" />.
580+
/// Returns the first element of the input task sequence given by <paramref name="source" />.
581581
/// </summary>
582582
///
583583
/// <param name="source">The input task sequence.</param>
@@ -628,8 +628,7 @@ module TaskSeq =
628628

629629
/// <summary>
630630
/// Returns the nth element of the input task sequence given by <paramref name="source" />,
631-
/// or <see cref="None" /> if the sequence does not contain enough elements, or <paramref name="index" />
632-
/// is negative.
631+
/// or <see cref="None" /> if the sequence does not contain enough elements.
633632
/// The index is zero-based, that is, using index 0 returns the first element.
634633
/// </summary>
635634
///
@@ -640,8 +639,7 @@ module TaskSeq =
640639

641640
/// <summary>
642641
/// Returns the nth element of the input task sequence given by <paramref name="source" />,
643-
/// or raises an exception if the sequence does not contain enough elements, or <paramref name="index" />
644-
/// is negative.
642+
/// or raises an exception if the sequence does not contain enough elements.
645643
/// The index is zero-based, that is, using index 0 returns the first element.
646644
/// </summary>
647645
///
@@ -823,7 +821,7 @@ module TaskSeq =
823821
val tryFindAsync: predicate: ('T -> #Task<bool>) -> source: taskSeq<'T> -> Task<'T option>
824822

825823
/// <summary>
826-
/// Returns the index, starting from zero for which the given function <paramref name="predicate" /> returns
824+
/// Returns the index, starting from zero, for which the given function <paramref name="predicate" /> returns
827825
/// <see cref="true" />. Returns <see cref="None" /> if no such element exists.
828826
/// If <paramref name="predicate" /> is asynchronous, consider using <see cref="TaskSeq.tryFindIndexAsync" />.
829827
/// </summary>
@@ -835,7 +833,7 @@ module TaskSeq =
835833
val tryFindIndex: predicate: ('T -> bool) -> source: taskSeq<'T> -> Task<int option>
836834

837835
/// <summary>
838-
/// Returns the index, starting from zero for which the given asynchronous function <paramref name="predicate" /> returns
836+
/// Returns the index, starting from zero, for which the given asynchronous function <paramref name="predicate" /> returns
839837
/// <see cref="true" />. Returns <see cref="None" /> if no such element exists.
840838
/// If <paramref name="predicate" /> is synchronous, consider using <see cref="TaskSeq.tryFindIndex" />.
841839
/// </summary>

0 commit comments

Comments
 (0)