anchor.diff:              print *, (string_arr_size + addl_num_entries)
   #endif
               
  -            allocate(tmp(size(arr) + addl_num_entries))
  -            tmp(1:size(arr)) = arr
  -            deallocate(arr)
  -            allocate(arr(size(tmp)))
  +            integer(i_byte)                              :: alloc_err
  +            character(len=100)                           :: err_msg
  +            
  +            new_size = size(arr) + addl_num_entries
  +            
  +            allocate(tmp(new_size), STAT=alloc_err)
  +            if (alloc_err /= 0) then
  +                write(err_msg, "(A, I0)") "Reallocator was unable to reallocate memory! Error code: ", alloc_err
  +                call error(trim(err_msg))
  +            end if
  +            tmp(1:size(arr)) = arr
  +            deallocate(arr)
  +            allocate(arr(new_size))
               arr = tmp
           end subroutine nc_diag_realloc_string
           
  
positive.code:             integer(i_llong),intent(in) :: addl_num_entries
              
              integer(i_long), dimension(:), allocatable   :: tmp
              
  #ifdef _DEBUG_MEM_
              call debug("Reallocating long array...")
  #endif
              
              allocate(tmp(size(arr) + addl_num_entries))
              tmp(1:size(arr)) = arr
              deallocate(arr)
              allocate(arr(size(tmp)))
              arr = tmp
              
  #ifdef _DEBUG_MEM_
  
negative.code:             integer(i_llong),intent(in) :: addl_num_entries
              
              logical, dimension(:), allocatable   :: tmp
              integer(i_llong)                     :: new_size
              
              integer(i_llong) :: logical_arr_size
              logical_arr_size = size(arr)
              
              new_size = logical_arr_size + addl_num_entries
              
  #ifdef _DEBUG_MEM_
              call debug("[logical] Allocating from...")
  