Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add exceptions section to Zip* docs #887

Merged
merged 3 commits into from
Nov 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions MoreLinq/EquiZip.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ static partial class MoreEnumerable
/// <exception cref="InvalidOperationException">
/// The input sequences are of different lengths.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3, 4 };
Expand Down Expand Up @@ -88,6 +92,11 @@ public static IEnumerable<TResult> EquiZip<TFirst, TSecond, TResult>(
/// <exception cref="InvalidOperationException">
/// The input sequences are of different lengths.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, or <paramref name="resultSelector"/> is <see
/// langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3, 4 };
Expand Down Expand Up @@ -138,6 +147,11 @@ public static IEnumerable<TResult> EquiZip<T1, T2, T3, TResult>(
/// <exception cref="InvalidOperationException">
/// The input sequences are of different lengths.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, <paramref name="fourth"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3, 4 };
Expand Down
42 changes: 42 additions & 0 deletions MoreLinq/Extensions.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1356,6 +1356,10 @@ public static partial class EquiZipExtension
/// <exception cref="InvalidOperationException">
/// The input sequences are of different lengths.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3, 4 };
Expand Down Expand Up @@ -1396,6 +1400,11 @@ public static IEnumerable<TResult> EquiZip<TFirst, TSecond, TResult>(
/// <exception cref="InvalidOperationException">
/// The input sequences are of different lengths.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, or <paramref name="resultSelector"/> is <see
/// langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3, 4 };
Expand Down Expand Up @@ -1439,6 +1448,11 @@ public static IEnumerable<TResult> EquiZip<T1, T2, T3, TResult>(
/// <exception cref="InvalidOperationException">
/// The input sequences are of different lengths.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, <paramref name="fourth"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3, 4 };
Expand Down Expand Up @@ -6764,6 +6778,10 @@ public static partial class ZipLongestExtension
/// A sequence that contains elements of the two input sequences,
/// combined by <paramref name="resultSelector"/>.
/// </returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = { 1, 2, 3 };
Expand Down Expand Up @@ -6803,6 +6821,11 @@ public static IEnumerable<TResult> ZipLongest<TFirst, TSecond, TResult>(
/// A sequence that contains elements of the three input sequences,
/// combined by <paramref name="resultSelector"/>.
/// </returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, or <paramref name="resultSelector"/> is <see
/// langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down Expand Up @@ -6846,6 +6869,11 @@ public static IEnumerable<TResult> ZipLongest<T1, T2, T3, TResult>(
/// A sequence that contains elements of the four input sequences,
/// combined by <paramref name="resultSelector"/>.
/// </returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, <paramref name="fourth"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down Expand Up @@ -6892,6 +6920,10 @@ public static partial class ZipShortestExtension
/// A projection of tuples, where each tuple contains the N-th element
/// from each of the argument sequences.</returns>
/// <example>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
/// var letters = new[] { "A", "B", "C", "D" };
Expand Down Expand Up @@ -6932,6 +6964,11 @@ public static IEnumerable<TResult> ZipShortest<TFirst, TSecond, TResult>(
/// <returns>
/// A projection of tuples, where each tuple contains the N-th element
/// from each of the argument sequences.</returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, or <paramref name="resultSelector"/> is <see
/// langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down Expand Up @@ -6978,6 +7015,11 @@ public static IEnumerable<TResult> ZipShortest<T1, T2, T3, TResult>(
/// <returns>
/// A projection of tuples, where each tuple contains the N-th element
/// from each of the argument sequences.</returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, <paramref name="fourth"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down
14 changes: 14 additions & 0 deletions MoreLinq/ZipLongest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ static partial class MoreEnumerable
/// A sequence that contains elements of the two input sequences,
/// combined by <paramref name="resultSelector"/>.
/// </returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = { 1, 2, 3 };
Expand Down Expand Up @@ -85,6 +89,11 @@ public static IEnumerable<TResult> ZipLongest<TFirst, TSecond, TResult>(
/// A sequence that contains elements of the three input sequences,
/// combined by <paramref name="resultSelector"/>.
/// </returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, or <paramref name="resultSelector"/> is <see
/// langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down Expand Up @@ -135,6 +144,11 @@ public static IEnumerable<TResult> ZipLongest<T1, T2, T3, TResult>(
/// A sequence that contains elements of the four input sequences,
/// combined by <paramref name="resultSelector"/>.
/// </returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, <paramref name="fourth"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down
14 changes: 14 additions & 0 deletions MoreLinq/ZipShortest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ static partial class MoreEnumerable
/// A projection of tuples, where each tuple contains the N-th element
/// from each of the argument sequences.</returns>
/// <example>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
/// var letters = new[] { "A", "B", "C", "D" };
Expand Down Expand Up @@ -84,6 +88,11 @@ public static IEnumerable<TResult> ZipShortest<TFirst, TSecond, TResult>(
/// <returns>
/// A projection of tuples, where each tuple contains the N-th element
/// from each of the argument sequences.</returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, or <paramref name="resultSelector"/> is <see
/// langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down Expand Up @@ -137,6 +146,11 @@ public static IEnumerable<TResult> ZipShortest<T1, T2, T3, TResult>(
/// <returns>
/// A projection of tuples, where each tuple contains the N-th element
/// from each of the argument sequences.</returns>
/// <exception cref="ArgumentNullException">
/// <paramref name="first"/>, <paramref name="second"/>, <paramref
/// name="third"/>, <paramref name="fourth"/>, or <paramref
/// name="resultSelector"/> is <see langword="null"/>.
/// </exception>
/// <example>
/// <code><![CDATA[
/// var numbers = new[] { 1, 2, 3 };
Expand Down