Files
clang-p2996/flang/test/Parser/unrecognized-dir.f90
Peter Klausler 68a27989d0 [flang] Accept and ignore compiler directives between internal subpro… (#89810)
…grams

The parser only recognizes compiler directives that appear within
internal / module subprograms, not those that might appear between them.
Extend to allow them between subprograms as well.
2024-04-24 15:25:19 -07:00

11 lines
276 B
Fortran

! RUN: %flang_fc1 -fsyntax-only %s 2>&1 | FileCheck %s
!CHECK: warning: Unrecognized compiler directive was ignored
!DIR$ Not a recognized directive
program main
contains
!CHECK: warning: Compiler directive ignored here
!DIR$ not in a subprogram
subroutine s
end
end