flu_dump_toBuf Subroutine

private subroutine flu_dump_toBuf(L, buf, length, iError)

Dump to a buffer and return the pointer to the resulting string.

Arguments

Type IntentOptional Attributes Name
type(flu_State) :: L
type(cbuf_type), intent(out) :: buf
integer :: length
integer :: iError

Calls

proc~~flu_dump_tobuf~~CallsGraph proc~flu_dump_tobuf flu_dump_toBuf interface~dump_lua_tobuf dump_lua_toBuf proc~flu_dump_tobuf->interface~dump_lua_tobuf

Called by

proc~~flu_dump_tobuf~~CalledByGraph proc~flu_dump_tobuf flu_dump_toBuf interface~flu_dump flu_dump interface~flu_dump->proc~flu_dump_tobuf proc~aot_file_to_buffer aot_file_to_buffer proc~aot_file_to_buffer->interface~flu_dump proc~open_config_file open_config_file proc~open_config_file->interface~flu_dump proc~aot_path_open_table aot_path_open_table proc~aot_path_open_table->proc~open_config_file interface~aot_path_open aot_path_open interface~aot_path_open->proc~aot_path_open_table proc~aot_path_open_fun aot_path_open_fun interface~aot_path_open->proc~aot_path_open_fun proc~aot_path_open_fun->proc~aot_path_open_table

Source Code

  subroutine flu_dump_toBuf(L, buf, length, iError)
    type(flu_State) :: L
    type(cbuf_type), intent(out) :: buf
    integer :: length
    integer :: iError

    type(c_ptr) :: string_c
    integer(kind=c_int) :: length_c
    integer(kind=c_int) :: iErr

    string_c = dump_lua_toBuf(L%state, length_c, iErr)
    iError = int(iErr)
    if (iError == 0) then
      length = int(length_c)
      buf%ptr = string_c
      call c_f_pointer(string_c, buf%buffer, [length])
    else
      length = 0
    end if
  end subroutine flu_dump_toBuf