mirror of
https://github.com/sfilippone/psblas3.git
synced 2026-10-13 09:29:04 +00:00
*** empty log message ***
This commit is contained in:
@@ -562,21 +562,24 @@ contains
|
||||
|
||||
subroutine i_vect_cnv(x,mold)
|
||||
class(psb_i_vect_type), intent(inout) :: x
|
||||
class(psb_i_base_vect_type), intent(in) :: mold
|
||||
class(psb_i_base_vect_type), intent(in), optional :: mold
|
||||
class(psb_i_base_vect_type), allocatable :: tmp
|
||||
integer(psb_ipk_) :: info
|
||||
|
||||
if (.not.allocated(x%v)) return
|
||||
#ifdef HAVE_MOLD
|
||||
allocate(tmp,stat=info,mold=mold)
|
||||
#else
|
||||
call mold%mold(tmp,info)
|
||||
#endif
|
||||
call x%v%sync()
|
||||
if (info == psb_success_) call tmp%bld(x%v%v)
|
||||
call x%v%free(info)
|
||||
call move_alloc(tmp,x%v)
|
||||
|
||||
if (present(mold)) then
|
||||
#ifdef HAVE_MOLD
|
||||
allocate(tmp,stat=info,mold=mold)
|
||||
#else
|
||||
call mold%mold(tmp,info)
|
||||
#endif
|
||||
if (allocated(x%v)) then
|
||||
call x%v%sync()
|
||||
if (info == psb_success_) call tmp%bld(x%v%v)
|
||||
call x%v%free(info)
|
||||
end if
|
||||
call move_alloc(tmp,x%v)
|
||||
end if
|
||||
end subroutine i_vect_cnv
|
||||
|
||||
end module psb_i_vect_mod
|
||||
|
||||
Reference in New Issue
Block a user