[WebAssembly] Fix asan issue from https://reviews.llvm.org/D121349
[llvm-project.git] / flang / test / Driver / std2018.f90
blobacc063e5fe4b56bbce940f589a9c13f7ddea5b7e
1 ! Ensure argument -std=f2018 works as expected.
3 !-----------------------------------------
4 ! FRONTEND FLANG DRIVER (flang-new -fc1)
5 !-----------------------------------------
6 ! RUN: %flang_fc1 -fsyntax-only %s 2>&1 | FileCheck %s --allow-empty --check-prefix=WITHOUT
7 ! RUN: %flang_fc1 -fsyntax-only -std=f2018 %s 2>&1 | FileCheck %s --check-prefix=GIVEN
8 ! RUN: %flang_fc1 -fsyntax-only -pedantic %s 2>&1 | FileCheck %s --check-prefix=GIVEN
10 !-----------------------------------------
11 ! EXPECTED OUTPUT WITHOUT
12 !-----------------------------------------
13 ! WITHOUT-NOT: A DO loop should terminate with an END DO or CONTINUE
15 !-----------------------------------------
16 ! EXPECTED OUTPUT WITH
17 !-----------------------------------------
18 ! GIVEN: A DO loop should terminate with an END DO or CONTINUE
20 subroutine foo2()
21 do 01 m=1,2
22 select case (m)
23 case default
24 print*, "default", m
25 case (1)
26 print*, "start"
27 01 end select
28 end subroutine