Sys_is_Little_Endian Function

public function Sys_is_Little_Endian() result(endian)

Determine if the system is little or big endian

Arguments

None

Return Value logical


Called by

proc~~sys_is_little_endian~~CalledByGraph proc~sys_is_little_endian Sys_is_Little_Endian proc~init_env init_env proc~init_env->proc~sys_is_little_endian proc~tem_start tem_start proc~tem_start->proc~init_env

Source Code

  function Sys_is_Little_Endian() result(endian)
    ! ---------------------------------------------------------------------------
    logical :: endian
    ! ---------------------------------------------------------------------------
    integer :: defInt
    character :: dummy(4)
    ! ---------------------------------------------------------------------------

    defInt = ichar('a')

    dummy = transfer(defInt, dummy(1), 4)

    endian = (dummy(1) == 'a')
  end function sys_is_little_endian