fdoc

functionin_categorypureprivate

pure logical function in_category(e, category)

True if entity e declares a name of category category: 1 procedures, 2 abstract interfaces, 3 types, 4 variables.

Arguments

NameTypeIntentAttributesDescription
etype(entity_t)in

the entity

categoryintegerin

the category

Result

NameTypeAttributesDescription
in_categorylogical

Calls

Source

Show the code
pure logical function in_category(e, category)
    type(entity_t), intent(in) :: e     !! the entity
    integer, intent(in) :: category     !! the category

    select case (category)
    case (1)
        in_category = e%kind == E_INTERFACE .or. ((is_procedure(e%kind) .or. &
                                                   e%kind == E_MODPROC) .and. e%iface /= IFACE_ABSTRACT)
    case (2)
        in_category = is_procedure(e%kind) .and. e%iface == IFACE_ABSTRACT
    case (3)
        in_category = e%kind == E_TYPE
    case default
        in_category = e%kind == E_VARIABLE
    end select
end function in_category

Graphs

Calls

Called by