view gcc/testsuite/gfortran.dg/error_stop_2.f08 @ 152:2b5abeee2509

update gcc11
author anatofuz
date Mon, 25 May 2020 07:50:57 +0900
parents 04ced10e8804
children
line wrap: on
line source

! { dg-do compile }
! PR44371 STOP parsing rejects valid code.
  real, dimension(5,5,5) :: i
  character(1) c, y
  y = 'y'
  read(y,*) c
  if (c=='x') stop; if (c=='X') stop
  if (c=='x') stop size(i); if (c=='X') stop

  if (c=='y') stop size(i) if (c=='Y') stop ! { dg-error "Syntax error in STOP" }
  end