xref: /llvm-project/flang/test/Semantics/blockconstruct02.f90 (revision 6c1ac141d3c98af9738bc77fcb55602cbff7751f)
1! RUN: %python %S/test_errors.py %s %flang_fc1
2! C1108  --  Save statement in a BLOCK construct shall not conatin a
3!            saved-entity-list that does not specify a common-block-name
4
5program  main
6  integer x, y, z
7  real r, s, t
8  common /argmnt2/ r, s, t
9  !ERROR: 'argmnt1' appears as a COMMON block in a SAVE statement but not in a COMMON statement
10  save /argmnt1/
11  block
12    !ERROR: SAVE statement in BLOCK construct may not contain a common block name 'argmnt2'
13    save /argmnt2/
14  end block
15end program
16