diff options
Diffstat (limited to 'flang/test/Semantics/call30.f90')
-rw-r--r-- | flang/test/Semantics/call30.f90 | 41 |
1 files changed, 19 insertions, 22 deletions
diff --git a/flang/test/Semantics/call30.f90 b/flang/test/Semantics/call30.f90 index f6725cdafcd1..3653c29faeeb 100644 --- a/flang/test/Semantics/call30.f90 +++ b/flang/test/Semantics/call30.f90 @@ -1,5 +1,5 @@ -! RUN: %python %S/test_errors.py %s %flang_fc1 -Werror -! This test is responsible for checking the fix for passing non-variables as +! RUN: %python %S/test_errors.py %s %flang_fc1 -Werror -pedantic +! This test is responsible for checking the fix for passing non-variables as ! actual arguments to subroutines/functions whose corresponding dummy argument ! expects a VOLATILE variable ! c.f. llvm-project GitHub issue #58973 @@ -25,36 +25,33 @@ module m subroutine test_all_subprograms() !WARNING: actual argument associated with VOLATILE dummy argument 'my_int=' is not a variable call vol_dum_int(6) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_int=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_int=' is not a variable call vol_dum_int(6+12) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_int=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_int=' is not a variable call vol_dum_int(6*12) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_int=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_int=' is not a variable call vol_dum_int(-6/2) - - !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable call vol_dum_real(3.141592653) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable - call vol_dum_real(3.141592653 + -10.6e-11) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable + call vol_dum_real(3.141592653 + (-10.6e-11)) + !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable call vol_dum_real(3.141592653 * 10.6e-11) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable - call vol_dum_real(3.141592653 / -10.6e-11) - - !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_real=' is not a variable + call vol_dum_real(3.141592653 / (-10.6e-11)) + !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable call vol_dum_complex((1., 3.2)) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable call vol_dum_complex((1., 3.2) + (-2., 3.14)) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable call vol_dum_complex((1., 3.2) * (-2., 3.14)) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_complex=' is not a variable call vol_dum_complex((1., 3.2) / (-2., 3.14)) - - !WARNING: actual argument associated with VOLATILE dummy argument 'my_int_arr=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_int_arr=' is not a variable call vol_dum_int_arr((/ 1, 2, 3, 4 /)) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_int_arr=' is not a variable + !WARNING: actual argument associated with VOLATILE dummy argument 'my_int_arr=' is not a variable call vol_dum_int_arr(reshape((/ 1, 2, 3, 4 /), (/ 2, 2/))) - !WARNING: actual argument associated with VOLATILE dummy argument 'my_int_arr=' is not a variable - call vol_dum_int_arr((/ 1, 2, 3, 4 /)) + !WARNING: actual argument associated with VOLATILE dummy argument 'my_int_arr=' is not a variable + call vol_dum_int_arr((/ 1, 2, 3, 4 /)) end subroutine test_all_subprograms end module m |