|
6 | 6 |
|
7 | 7 | use crate::provider::chinese_based::PackedChineseBasedYearInfo;
|
8 | 8 |
|
9 |
| -pub const STARTING_YEAR: i32 = 1901; |
| 9 | +pub const STARTING_YEAR: i32 = 1900; |
10 | 10 |
|
11 | 11 | #[rustfmt::skip]
|
12 | 12 | pub const DATA: &[PackedChineseBasedYearInfo] = {
|
13 | 13 | use calendrical_calculations::gregorian::fixed_from_gregorian as gregorian;
|
14 | 14 | let l = true; // long
|
15 | 15 | let s = false; // short
|
16 | 16 | &[
|
| 17 | + // This data comes from the KASI website |
| 18 | + // https://astro.kasi.re.kr/life/pageView/5 |
| 19 | + PackedChineseBasedYearInfo::new(1900, [s, l, s, s, l, s, l, l, s, l, l, s, l], Some(9), gregorian(1900, 1, 31)), |
17 | 20 | PackedChineseBasedYearInfo::new(1901, [s, l, s, s, l, s, l, s, l, l, l, s, s], None, gregorian(1901, 2, 19)),
|
18 | 21 | PackedChineseBasedYearInfo::new(1902, [l, s, l, s, s, l, s, l, s, l, l, l, s], None, gregorian(1902, 2, 8)),
|
19 |
| - PackedChineseBasedYearInfo::new(1903, [s, l, s, l, s, s, l, s, s, l, l, l, s], Some(6), gregorian(1903, 1, 29)), |
20 |
| - PackedChineseBasedYearInfo::new(1904, [l, l, s, l, s, s, l, s, l, s, l, s, s], None, gregorian(1904, 2, 16)), |
21 |
| - PackedChineseBasedYearInfo::new(1905, [l, l, l, s, l, s, s, l, s, l, s, l, s], None, gregorian(1905, 2, 4)), |
| 22 | + PackedChineseBasedYearInfo::new(1903, [s, l, s, l, s, s, l, s, s, l, l, s, l], Some(6), gregorian(1903, 1, 29)), |
| 23 | + PackedChineseBasedYearInfo::new(1904, [l, l, s, l, s, s, l, s, s, l, l, s, s], None, gregorian(1904, 2, 16)), |
| 24 | + PackedChineseBasedYearInfo::new(1905, [l, l, s, l, l, s, s, l, s, l, s, l, s], None, gregorian(1905, 2, 4)), |
22 | 25 | PackedChineseBasedYearInfo::new(1906, [s, l, l, s, l, s, l, s, l, s, l, s, l], Some(5), gregorian(1906, 1, 25)),
|
23 | 26 | PackedChineseBasedYearInfo::new(1907, [s, l, s, l, s, l, l, s, l, s, l, s, s], None, gregorian(1907, 2, 13)),
|
24 |
| - PackedChineseBasedYearInfo::new(1908, [l, s, l, s, l, s, l, s, l, l, s, l, s], None, gregorian(1908, 2, 2)), |
| 27 | + PackedChineseBasedYearInfo::new(1908, [l, s, s, l, l, s, l, s, l, l, s, l, s], None, gregorian(1908, 2, 2)), |
25 | 28 | PackedChineseBasedYearInfo::new(1909, [s, l, s, s, l, s, l, s, l, l, l, s, l], Some(3), gregorian(1909, 1, 22)),
|
26 | 29 | PackedChineseBasedYearInfo::new(1910, [s, l, s, s, l, s, l, s, l, l, l, s, s], None, gregorian(1910, 2, 10)),
|
27 |
| - PackedChineseBasedYearInfo::new(1911, [l, s, l, s, s, l, s, s, l, l, l, s, l], Some(7), gregorian(1911, 1, 30)), |
| 30 | + PackedChineseBasedYearInfo::new(1911, [l, s, l, s, s, l, s, s, l, l, s, l, l], Some(7), gregorian(1911, 1, 30)), |
28 | 31 | PackedChineseBasedYearInfo::new(1912, [l, s, l, s, s, l, s, s, l, l, s, l, s], None, gregorian(1912, 2, 18)),
|
29 | 32 | PackedChineseBasedYearInfo::new(1913, [l, l, s, l, s, s, l, s, s, l, s, l, s], None, gregorian(1913, 2, 6)),
|
30 | 33 | PackedChineseBasedYearInfo::new(1914, [l, l, s, l, l, s, s, l, s, l, s, s, l], Some(6), gregorian(1914, 1, 26)),
|
@@ -163,6 +166,7 @@ pub const DATA: &[PackedChineseBasedYearInfo] = {
|
163 | 166 | PackedChineseBasedYearInfo::new(2047, [l, s, l, l, s, l, s, l, s, s, l, s, l], Some(6), gregorian(2047, 1, 26)),
|
164 | 167 | PackedChineseBasedYearInfo::new(2048, [s, l, l, s, l, l, s, l, s, l, s, s, s], None, gregorian(2048, 2, 14)),
|
165 | 168 | PackedChineseBasedYearInfo::new(2049, [l, s, l, s, l, l, s, l, l, s, l, s, s], None, gregorian(2049, 2, 2)),
|
| 169 | + // This data is precomputed using Reingold calculations |
166 | 170 | PackedChineseBasedYearInfo::new(2050, [l, s, s, l, s, l, s, l, l, s, l, l, s], Some(4), gregorian(2050, 1, 23)),
|
167 | 171 | PackedChineseBasedYearInfo::new(2051, [l, s, s, l, s, l, s, l, s, l, l, l, s], None, gregorian(2051, 2, 11)),
|
168 | 172 | PackedChineseBasedYearInfo::new(2052, [s, l, s, s, l, s, s, l, l, s, l, l, l], Some(9), gregorian(2052, 2, 1)),
|
|
0 commit comments