is_valid_year Function

public pure function is_valid_year(y)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: y

Return Value logical


Calls

proc~~is_valid_year~~CallsGraph proc~is_valid_year is_valid_year proc~is_between is_between proc~is_valid_year->proc~is_between

Called by

proc~~is_valid_year~~CalledByGraph proc~is_valid_year is_valid_year proc~is_valid_date~2 is_valid_date proc~is_valid_date~2->proc~is_valid_year proc~test_is_valid_year~2 test_is_valid_year proc~test_is_valid_year~2->proc~is_valid_year proc~parse_date parse_date proc~parse_date->proc~is_valid_date~2 proc~test_is_valid_date~2 test_is_valid_date proc~test_is_valid_date~2->proc~is_valid_date~2 proc~construct_iso8601date construct_ISO8601Date proc~construct_iso8601date->proc~parse_date proc~test_parse_date~2 test_parse_date proc~test_parse_date~2->proc~parse_date interface~iso8601date ISO8601Date interface~iso8601date->proc~construct_iso8601date

Source Code

   pure logical function is_valid_year(y)
      integer, intent(in) :: y
! Strict ISO8601 compliance does not allow years before 1583
#ifdef STRICT_ISO8601
      integer, parameter :: LB_YEAR = 1582
#else
      integer, parameter :: LB_YEAR = -1
#endif
      integer, parameter :: UB_YEAR = 10000

      is_valid_year = is_between(LB_YEAR, UB_YEAR, y)
   end function is_valid_year