fdoc

functionextension_ofpureprivate

pure character(len=merge(0,len(path)-index(path,'.',back=.true.),index(path,'.',back=.true.)==0)) function extension_of(path) result(ext)

The extension of path, without the dot, or ''.

Arguments

NameTypeIntentAttributesDescription
pathcharacter(len=*)in

the path

Result

NameTypeAttributesDescription
extcharacter(len=merge(0,len(path)-index(path,'.',back=.true.),index(path,'.',back=.true.)==0))private

Source

Show the code
pure function extension_of(path) result(ext)
    character(len=*), intent(in) :: path    !! the path
    character(len=merge(0, len(path) - index(path, '.', back=.true.), index(path, '.', back=.true.) == 0)) :: ext
    ext = path(len(path) - len(ext) + 1:)
end function extension_of

Graphs

Called by