Function actix_web::cookie::time::util::days_in_year
pub const fn days_in_year(year: i32) -> u16
Available on crate feature
cookies
only.Expand description
Get the number of calendar days in a given year.
The returned value will always be either 365 or 366.
assert_eq!(days_in_year(1900), 365);
assert_eq!(days_in_year(2000), 366);
assert_eq!(days_in_year(2004), 366);
assert_eq!(days_in_year(2005), 365);
assert_eq!(days_in_year(2100), 365);