fdoc

functionvariable_typeprivate

integer function variable_type(p, id) result(found)

The derived type of variable id, or 0.

Arguments

NameTypeIntentAttributesDescription
ptype(project_t)in

the project

idintegerin

the variable

Result

NameTypeAttributesDescription
foundinteger

Calls

Source

Show the code
integer function variable_type(p, id) result(found)
    type(project_t), intent(in) :: p    !! the project
    integer, intent(in) :: id           !! the variable

    found = 0
    associate (v => p%list%box(id)%e)
        if (.not. allocated(v%proto)) return
        if (v%vartype /= 'type' .and. v%vartype /= 'class') return
        found = find_symbol(p, v%parent, lowercase(v%proto(1)%s), 3)
    end associate
end function variable_type

Graphs

Calls

Called by