view gcc/testsuite/gfortran.dg/selected_char_kind_4.f90 @ 152:2b5abeee2509

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

! { dg-do run }
!
! Check that runtime result values of SELECTED_CHAR_KIND agree with
! front-end simplification results.
!
  implicit none
  character(len=20) :: s

  s = "ascii"
  if (selected_char_kind(s) /= selected_char_kind("ascii")) STOP 1

  s = "default"
  if (selected_char_kind(s) /= selected_char_kind("default")) STOP 2

  s = "iso_10646"
  if (selected_char_kind(s) /= selected_char_kind("iso_10646")) STOP 3

  s = ""
  if (selected_char_kind(s) /= selected_char_kind("")) STOP 4

  s = "invalid"
  if (selected_char_kind(s) /= selected_char_kind("invalid")) STOP 5

end