aot_table_first Function

public function aot_table_first(L, thandle) result(exists)

Load the first key-value pair of table thandle on the stack.

This serves as an entry point, further traversal can be done by flu_next(L, thandle). If there are no entries in the table the function returns false, otherwise the result will be true.

Arguments

Type IntentOptional Attributes Name
type(flu_State) :: L

Handle for the Lua script.

integer, intent(in) :: thandle

Handle to the table to get the first entry of.

Return Value logical

The return value signals, if there actually is such a first entry.


Calls

proc~~aot_table_first~~CallsGraph proc~aot_table_first aot_table_first proc~flu_next flu_next proc~aot_table_first->proc~flu_next proc~flu_pushnil flu_pushnil proc~aot_table_first->proc~flu_pushnil interface~lua_next lua_next proc~flu_next->interface~lua_next interface~lua_pushnil lua_pushnil proc~flu_pushnil->interface~lua_pushnil

Called by

proc~~aot_table_first~~CalledByGraph proc~aot_table_first aot_table_first proc~aot_table_length aot_table_length proc~aot_table_length->proc~aot_table_first proc~get_top_double_v get_top_double_v proc~get_top_double_v->proc~aot_table_first proc~get_top_double_v->proc~aot_table_length proc~get_top_double_vvect get_top_double_vvect proc~get_top_double_vvect->proc~aot_table_first proc~get_top_double_vvect->proc~aot_table_length proc~get_top_extdouble_v get_top_extdouble_v proc~get_top_extdouble_v->proc~aot_table_first proc~get_top_extdouble_v->proc~aot_table_length proc~get_top_extdouble_vvect get_top_extdouble_vvect proc~get_top_extdouble_vvect->proc~aot_table_first proc~get_top_extdouble_vvect->proc~aot_table_length proc~get_top_integer_v get_top_integer_v proc~get_top_integer_v->proc~aot_table_first proc~get_top_integer_v->proc~aot_table_length proc~get_top_integer_vvect get_top_integer_vvect proc~get_top_integer_vvect->proc~aot_table_first proc~get_top_integer_vvect->proc~aot_table_length proc~get_top_logical_v get_top_logical_v proc~get_top_logical_v->proc~aot_table_first proc~get_top_logical_v->proc~aot_table_length proc~get_top_logical_vvect get_top_logical_vvect proc~get_top_logical_vvect->proc~aot_table_first proc~get_top_logical_vvect->proc~aot_table_length proc~get_top_long_v get_top_long_v proc~get_top_long_v->proc~aot_table_first proc~get_top_long_v->proc~aot_table_length proc~get_top_long_vvect get_top_long_vvect proc~get_top_long_vvect->proc~aot_table_first proc~get_top_long_vvect->proc~aot_table_length proc~get_top_quadruple_v get_top_quadruple_v proc~get_top_quadruple_v->proc~aot_table_first proc~get_top_quadruple_v->proc~aot_table_length proc~get_top_quadruple_vvect get_top_quadruple_vvect proc~get_top_quadruple_vvect->proc~aot_table_first proc~get_top_quadruple_vvect->proc~aot_table_length proc~get_top_real_v get_top_real_v proc~get_top_real_v->proc~aot_table_first proc~get_top_real_v->proc~aot_table_length proc~get_top_real_vvect get_top_real_vvect proc~get_top_real_vvect->proc~aot_table_first proc~get_top_real_vvect->proc~aot_table_length proc~get_top_string_v get_top_string_v proc~get_top_string_v->proc~aot_table_first proc~get_top_string_v->proc~aot_table_length proc~get_top_string_vvect get_top_string_vvect proc~get_top_string_vvect->proc~aot_table_first proc~get_top_string_vvect->proc~aot_table_length interface~aot_top_get_val aot_top_get_val interface~aot_top_get_val->proc~get_top_quadruple_vvect interface~aot_top_get_val~2 aot_top_get_val interface~aot_top_get_val~2->proc~get_top_quadruple_v interface~aot_top_get_val~4 aot_top_get_val interface~aot_top_get_val~4->proc~get_top_double_vvect interface~aot_top_get_val~4->proc~get_top_integer_vvect interface~aot_top_get_val~4->proc~get_top_logical_vvect interface~aot_top_get_val~4->proc~get_top_long_vvect interface~aot_top_get_val~4->proc~get_top_real_vvect interface~aot_top_get_val~4->proc~get_top_string_vvect interface~aot_top_get_val~5 aot_top_get_val interface~aot_top_get_val~5->proc~get_top_double_v interface~aot_top_get_val~5->proc~get_top_integer_v interface~aot_top_get_val~5->proc~get_top_logical_v interface~aot_top_get_val~5->proc~get_top_long_v interface~aot_top_get_val~5->proc~get_top_real_v interface~aot_top_get_val~5->proc~get_top_string_v interface~aot_top_get_val~6 aot_top_get_val interface~aot_top_get_val~6->proc~get_top_extdouble_vvect interface~aot_top_get_val~7 aot_top_get_val interface~aot_top_get_val~7->proc~get_top_extdouble_v

Source Code

  function aot_table_first(L, thandle) result(exists)
    type(flu_state) :: L !! Handle for the Lua script.

    !> Handle to the table to get the first entry of.
    integer, intent(in) :: thandle

    !> The return value signals, if there actually is such a first entry.
    logical :: exists

    if (thandle /= 0) then
      call flu_pushnil(L)
      exists = flu_next(L, thandle)
    else
      exists = .false.
    end if
  end function aot_table_first