stack_restore Subroutine

private pure subroutine stack_restore(self, scopes)

Replace the open constructs by scopes (outermost first).

Type Bound

scope_stack_t

Arguments

Type IntentOptional Attributes Name
class(scope_stack_t), intent(inout) :: self

the stack

type(scope_t), intent(in) :: scopes(:)

a saved stack (see stack_snapshot)


Calls

proc~~stack_restore~~CallsGraph proc~stack_restore scope_stack_t%stack_restore proc~stack_push scope_stack_t%stack_push proc~stack_restore->proc~stack_push

Called by

proc~~stack_restore~~CalledByGraph proc~stack_restore scope_stack_t%stack_restore proc~analyze_structure analyze_structure proc~analyze_structure->proc~stack_restore proc~format_pass format_pass proc~format_pass->proc~analyze_structure proc~format_text format_text proc~format_text->proc~format_pass proc~relayout relayout proc~format_text->proc~relayout proc~relayout->proc~format_pass proc~process_text process_text proc~process_text->proc~format_text proc~process_file process_file proc~process_file->proc~process_text proc~process_stdin process_stdin proc~process_stdin->proc~process_text proc~run run proc~run->proc~process_file proc~run->proc~process_stdin

Source Code

pure subroutine stack_restore(self, scopes)
    !! Replace the open constructs by `scopes` (outermost first).
    class(scope_stack_t), intent(inout) :: self  !! the stack
    type(scope_t), intent(in) :: scopes(:)        !! a saved stack (see [[stack_snapshot]])
    integer :: j
    self%top = 0
    do j = 1, size(scopes)
        call self%push(scopes(j))
    end do
end subroutine stack_restore