| 54 | }; |
| 55 | |
| 56 | static bool IsLeapYear(std::int32_t year) noexcept |
| 57 | { |
| 58 | if (year == -1) { |
| 59 | year = DateTime::UtcNow().GetYear(); |
| 60 | } |
| 61 | |
| 62 | return (year % 4 == 0 && ((year % 100) != 0 || (year % 400) == 0)); |
| 63 | } |
| 64 | |
| 65 | static std::int32_t GetNumberOfDaysInMonth(std::int32_t month, std::int32_t year) noexcept |
| 66 | { |
no test coverage detected