fdoc

subroutinetype_uses_sectionprivate

subroutine type_uses_section(site, id, b)

Write where type id is used, if it is.

Arguments

NameTypeIntentAttributesDescription
sitetype(site_t)in

the site

idintegerin

the type

btype(buffer_t)inout

the HTML

Calls

Called by

Source

Show the code
subroutine type_uses_section(site, id, b)
    type(site_t), intent(in) :: site        !! the site
    integer, intent(in) :: id               !! the type
    type(buffer_t), intent(inout) :: b      !! the HTML

    associate (uses => site%type_uses(site%use_slot(id)))
        if (.not. (allocated(uses%arguments) .or. allocated(uses%results) .or. &
                   allocated(uses%components) .or. allocated(uses%variables))) return
        call add(b, '<h2 id="uses-of-type">Where it is used</h2>'//achar(10))
        call use_group(site, 'Argument of', uses%arguments, b)
        call use_group(site, 'Returned by', uses%results, b)
        call use_group(site, 'Component of', uses%components, b)
        call use_group(site, 'Module variables', uses%variables, b)
    end associate
end subroutine type_uses_section