We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 525a489 commit 171c377Copy full SHA for 171c377
src/include/utils/datetime.h
@@ -271,6 +271,11 @@ extern const char *const months[]; /* months (3-char abbreviations) */
271
extern const char *const days[]; /* days (full names) */
272
extern const int day_tab[2][13];
273
274
+/*
275
+ * These are the rules for the Gregorian calendar, which was adopted in 1582.
276
+ * However, we use this calculation for all prior years as well because the
277
+ * SQL standard specifies use of the Gregorian calendar.
278
+ */
279
#define isleap(y) (((y) % 4) == 0 && (((y) % 100) != 0 || ((y) % 400) == 0))
280
281
0 commit comments