PROGRAM namedifblock

  IMPLICIT NONE
  INTEGER :: state=1
  REAL :: phase
  REAL, PARAMETER :: pi=3.1415, pi_by_2=pi*0.5

  phase = 10.5
  phasetest: IF (state == 1) THEN
     IF (phase < pi_by_2) THEN
       PRINT*, 'phase < pi_by_2'
     ELSE
       PRINT*, 'phase >= pi_by_2'
     ENDIF
  ELSE IF (state == 2) THEN 
      IF (phase > pi) PRINT *, 'A bit odd here'
  ELSE 
    IF (phase < pi) THEN
      PRINT*, 'phase < pi'   
    ENDIF
  ENDIF 

END PROGRAM namedifblock
