diff options
| author | Julian Taylor <jtaylor.debian@googlemail.com> | 2017-04-15 12:28:41 +0200 |
|---|---|---|
| committer | Julian Taylor <jtaylor.debian@googlemail.com> | 2017-05-02 21:30:36 +0200 |
| commit | b8d0498eb1463e900a6c07311c0c1f80f5611bad (patch) | |
| tree | 5dddea4b52578f8fdec6d73d12d63c2bbfba9d08 /numpy/f2py/tests/src/string | |
| parent | 43914a4421fbabdd63a1cb73ef4c48d626498aaa (diff) | |
| download | numpy-b8d0498eb1463e900a6c07311c0c1f80f5611bad.tar.gz | |
TST: add a char array input test
Diffstat (limited to 'numpy/f2py/tests/src/string')
| -rw-r--r-- | numpy/f2py/tests/src/string/char.f90 | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/numpy/f2py/tests/src/string/char.f90 b/numpy/f2py/tests/src/string/char.f90 new file mode 100644 index 000000000..bb7985ce5 --- /dev/null +++ b/numpy/f2py/tests/src/string/char.f90 @@ -0,0 +1,29 @@ +MODULE char_test + +CONTAINS + +SUBROUTINE change_strings(strings, n_strs, out_strings) + IMPLICIT NONE + + ! Inputs + INTEGER, INTENT(IN) :: n_strs + CHARACTER, INTENT(IN), DIMENSION(2,n_strs) :: strings + CHARACTER, INTENT(OUT), DIMENSION(2,n_strs) :: out_strings + +!f2py INTEGER, INTENT(IN) :: n_strs +!f2py CHARACTER, INTENT(IN), DIMENSION(2,n_strs) :: strings +!f2py CHARACTER, INTENT(OUT), DIMENSION(2,n_strs) :: strings + + ! Misc. + INTEGER*4 :: j + + + DO j=1, n_strs + out_strings(1,j) = strings(1,j) + out_strings(2,j) = 'A' + END DO + +END SUBROUTINE change_strings + +END MODULE char_test + |
