Skip to content

Commit 76aeefb

Browse files
authored
Document DateOnly.AddDays exception (#94635)
1 parent 05bb403 commit 76aeefb

File tree

1 file changed

+3
-0
lines changed
  • src/libraries/System.Private.CoreLib/src/System

1 file changed

+3
-0
lines changed

src/libraries/System.Private.CoreLib/src/System/DateOnly.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,9 @@ public static DateOnly FromDayNumber(int dayNumber)
115115
/// </summary>
116116
/// <param name="value">The number of days to add. To subtract days, specify a negative number.</param>
117117
/// <returns>An instance whose value is the sum of the date represented by this instance and the number of days represented by value.</returns>
118+
/// <exception cref="ArgumentOutOfRangeException">
119+
/// Thrown if the resulting value would be greater than <see cref="MaxValue"/>.
120+
/// </exception>
118121
public DateOnly AddDays(int value)
119122
{
120123
int newDayNumber = _dayNumber + value;

0 commit comments

Comments
 (0)