1. day_count can be implicitly converted to an int
2. day_count+1 yields an integer with a value one higher than the integer value of day_count
3. days(day_count+1) casts that integer to an object of type days
4. which is assigned to day_count
Expression day_count+1 is implicitly converted to an integral type. However an integral expression can not be implicitly converted to an enumeration type. You shall explicitly specify the type of enumeration to which you want to convert an integral expression. And this record
means that expression
must be converted to the enumeration type enum days.