I have a user-defined variable that contains an integer component that I want to use as an index for a do-loop. However, this generates the error
Error error #5082: Syntax error, found '%' when expecting one of: =
The following is the code fragment:
type :: myvar integer(kind = 4) :: i end type myvar type(myvar) :: a do a%i = 1,10 ! body of loop end do read *
Does it mean that the use of a%i as an index is illegal or is the compiler not setup to recognize the %.