Create new YearMonth's year and month with valid value
const YearMonth(this.year, this.month) : assert(month >= 1 && month <= 12);