Function imm_code_to_dates
pub(crate) fn imm_code_to_dates(
code: &str,
cycle: &str,
) -> PyResult<(NaiveDate, NaiveDate)>Expand description
The unadjusted (start, end) reference period an IMM code names — the
inverse of imm_code_of, which renders the end.
end is the third Wednesday of the code’s own month; start is the third
Wednesday of the previous IMM in cycle. Raises ValueError naming the
code where it is not MMM + YY, its year falls outside 2000–2099, or the
quarterly cycle is asked for a month it does not admit.