Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions fpm.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ author = ["Damian Rouson"]
maintainer = "damian@sourceryinstitute.org"
copyright = "2020 Sourcery Institute"

[dependencies]
assert = {git = "https://github.com/sourceryinstitute/assert", tag = "1.0.0"}

[dev-dependencies]
vegetables = {git = "https://gitlab.com/everythingfunctional/vegetables", tag = "v6.0.1"}

Expand Down
6 changes: 3 additions & 3 deletions src/array_functions_implementation.f90
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
! contract # NRC-HQ-60-17-C-0007
!
submodule(array_functions_interface) array_functions_implementation
use assertions_interface, only : assert, assertions
use assert_m, only : assert
implicit none
contains

module procedure column_vectors
integer i, j, k

associate( n => shape(vector_field) )
if (assertions) call assert(size(n)==4, "3D vector field input")
call assert(size(n)==4, "3D vector field input")
allocate( array_of_3D_column_vectors( n(4), product(n(1:3)) ) )
do concurrent( i=1:n(1), j=1:n(2), k=1:n(3) )
associate( id => (k-1)*PRODUCT(n(1:2)) + (j-1)*n(1) + i )
Expand All @@ -34,7 +34,7 @@
associate(cols=>size(a,2)+size(b,2))
associate(a_unrolled=>reshape(a,[size(a)]))
associate(b_unrolled=>reshape(b,[size(b)]))
if (assertions) call assert( rows==size(b,1), "array_functions: compatible shapes")
call assert( rows==size(b,1), "array_functions: compatible shapes")
concatenated = reshape( [a_unrolled, b_unrolled ],[rows, cols] )
end associate; end associate; end associate; end associate
end procedure
Expand Down
62 changes: 0 additions & 62 deletions src/assertions_implementation.F90

This file was deleted.

47 changes: 0 additions & 47 deletions src/assertions_interface.F90

This file was deleted.

6 changes: 3 additions & 3 deletions src/data-partition-implementation.F90
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
submodule(data_partition_interface) data_partition_implementation
use assertions_interface, only : assert, assertions
use assert_m, only : assert
implicit none

logical, parameter :: verbose=.false.
Expand Down Expand Up @@ -45,12 +45,12 @@ pure function overflow(im, excess) result(extra_datum)
#endif

module procedure first
if (assertions) call assert( allocated(first_datum), "allocated(first_datum)")
call assert( allocated(first_datum), "allocated(first_datum)")
first_index= first_datum( image_number )
end procedure

module procedure last
if (assertions) call assert( allocated(last_datum), "allocated(last_datum)")
call assert( allocated(last_datum), "allocated(last_datum)")
last_index = last_datum( image_number )
end procedure

Expand Down
2 changes: 1 addition & 1 deletion src/emulated_intrinsics_implementation.F90
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
! contract # NRC-HQ-60-17-C-0007
!
submodule(emulated_intrinsics_interface) emulated_intrinsics_implementation
use assertions_interface, only : assert
use assert_m, only : assert
implicit none

contains
Expand Down