Returns the value at the given position from the list.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(list_timerenv_type), | intent(in) | :: | list | |||
integer, | intent(in) | :: | pos |
Position in the list - must fulfill 0 < pos < list_size+1 . |
FUNCTION list_timerenv_get(list, pos) RESULT(value) # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" !! Returns the value at the given position from the list. # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" TYPE(list_timerenv_type), intent(in) :: list # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" INTEGER, intent(in) :: pos # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" !! Position in the list - must fulfill 0 < pos < list_size+1 . # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" TYPE(timer_env_type), POINTER :: value # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" IF(.not. ASSOCIATED(list%arr)) & # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" DBCSR_ABORT("list_timerenv_get: list is not initialized.") # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" IF(pos < 1)& # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" DBCSR_ABORT("list_timerenv_get: pos < 1") # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" IF(pos > list%size)& # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" DBCSR_ABORT("list_timerenv_get: pos > size") # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" value => list%arr(pos)%p%value # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" # 21 "/__w/dbcsr/dbcsr/src/core/dbcsr_list_timerenv.F" END FUNCTION list_timerenv_get