I'm trying to use the ALL and ANY commands in a code similar to the following one:
integer :: Ordering(1:Number_Derivatives)
do i = 1, Number_Derivatives
do j = 1, Number_Derivatives
if(any(Ordering(1:i-1) == j)) cycle
Looking at the Fortran 95 standard and the Intel language reference guide, the previous code should not execute the cycle command when i = 1, since then the Mask for the command ANY has size zero, since the triplet turns out to be empty: 1:i-1 = 1:0.
Instead, the command any(Ordering(1:i-1) == j) for i = 1 returns nothing, not a true and not a false.
I would like to know if this is my interpretation error from the documents or it is a possible bug of the compiler.
Thanks in advance and greetings from Spain,