functionqualified_namerecursiveprivate
recursive character(len=:) function qualified_name(p, id) result(name)
The name of entity id with those around it, up to its top-level unit.
Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
| p | type(project_t) | in | the project | |
| id | integer | in | the entity |
Result
| Name | Type | Attributes | Description |
|---|---|---|---|
| name | character(len=:) | privateallocatable |
Calls
Source
Show the code
recursive function qualified_name(p, id) result(name)
type(project_t), intent(in) :: p !! the project
integer, intent(in) :: id !! the entity
character(len=:), allocatable :: name
name = lowercase(p%list%box(id)%e%name)
if (p%list%box(id)%e%parent == 0) return
if (p%list%box(p%list%box(id)%e%parent)%e%kind == E_FILE) return
name = qualified_name(p, p%list%box(id)%e%parent)//'/'//name
end function qualified_name