Returns true if this date is in the same year as other.
true
other
bool isSameYear(DateTime other) => year == other.year;