1! Check to ensure result is calculated from unmodified 2! version of the right-hand-side in WHERE statements. 3program where_19 4 integer :: a(4) 5 integer :: b(3) 6 integer :: c(3) 7 equivalence (a(1), b(1)), (a(2), c(1)) 8 9 a = (/1, 2, 3, 4/) 10 where (b .gt. 1) 11 c = b 12 endwhere 13 if (any (a .ne. (/1, 2, 2, 3/))) & 14 STOP 1 15 16 a = (/1, 2, 3, 4/) 17 where (c .gt. 1) 18 b = c 19 endwhere 20 if (any (a .ne. (/2, 3, 4, 4/))) & 21 STOP 2 22end program 23 24