fdoc

subroutinedoxygen_metaprivate

subroutine doxygen_meta(line, moved)

If line is a doxygen command, blank it and add it to moved as a metadata line.

Arguments

NameTypeIntentAttributesDescription
linecharacter(len=:)inoutallocatable

the doc line

movedtype(string_t)inoutallocatabledimension(:)

the metadata lines

Calls

Source

Show the code
subroutine doxygen_meta(line, moved)
    character(len=:), allocatable, intent(inout) :: line    !! the doc line
    type(string_t), allocatable, intent(inout) :: moved(:)  !! the metadata lines
    character(len=len(line)) :: text
    integer :: at, stop_at

    if (len(line) == 0) return
    text = adjustl(line)
    if (text(1:1) /= '@') return
    stop_at = index(trim(text), ' ')
    if (stop_at < 3) return
    at = len_trim(text(:stop_at))
    select case (text(2:at))
    case ('see')
        line = '[['//strip(first_word_of(text(stop_at:)))//']]'//text(stop_at + len(first_word_of(strip(text(stop_at:)))) + 1:)
        return
    case ('note', 'warning', 'todo', 'bug', 'history')
        return
    case ('brief')
        call push(moved, 'summary: '//strip(text(stop_at:)))
    case default
        call push(moved, text(2:at)//': '//strip(text(stop_at:)))
    end select
    line = ''
end subroutine doxygen_meta

Graphs

Calls

Called by