| 1 |
! { dg-do run } |
| 2 |
! |
| 3 |
! PR fortran/ |
| 4 |
! |
| 5 |
! The trans-*.c part of the compiler did no know |
| 6 |
! that mvbits is an elemental function. |
| 7 |
! |
| 8 |
! Test case contributed by P.H. Lundow. |
| 9 |
! |
| 10 |
program main |
| 11 |
implicit none |
| 12 |
integer :: a( 2 ), b( 2 ) |
| 13 |
integer :: x, y |
| 14 |
|
| 15 |
a = 1 |
| 16 |
b = 0 |
| 17 |
x = 1 |
| 18 |
y = 0 |
| 19 |
|
| 20 |
call mvbits (a, 0, 1, b, 1) |
| 21 |
call mvbits (x, 0, 1, y, 1) |
| 22 |
|
| 23 |
! write (*, *) 'a: ', a |
| 24 |
! write (*, *) 'x: ', x |
| 25 |
! write (*, *) |
| 26 |
! write (*, *) 'b: ', b |
| 27 |
! write (*, *) 'y: ', y |
| 28 |
! write (*, *) |
| 29 |
|
| 30 |
if ( any (b /= y) ) STOP 1 |
| 31 |
end program main |