[flang][openacc] Use OpenACC terminator instead of fir.unreachable after Stop stmt...
[llvm-project.git] / flang / test / Driver / prescanner-diag.f90
blobe133628f71d772368e8d242774779e4fc6242535
1 ! Test that the driver correctly reports diagnostics from the prescanner, no
2 ! matter what driver action/phase is run. We need this test as Flang currently
3 ! has no central API for managing the diagnostics. For this reason the driver
4 ! needs to make sure that the diagnostics are indeed issued (rather that relying
5 ! on some DiagnosticsEngine).
7 ! Test with -E (i.e. PrintPreprocessedAction, stops after prescanning)
8 ! RUN: %flang -E -I %S/Inputs/ %s 2>&1 | FileCheck %s
9 ! RUN: %flang_fc1 -E -I %S/Inputs/ %s 2>&1 | FileCheck %s
11 ! Test with -fsyntax-only (i.e. ParseSyntaxOnlyAction, stops after semantic checks)
12 ! RUN: %flang -fsyntax-only -I %S/Inputs/ %s 2>&1 | FileCheck %s
13 ! RUN: %flang_fc1 -fsyntax-only -I %S/Inputs/ %s 2>&1 | FileCheck %s
15 ! CHECK: prescanner-diag.f90:[[#@LINE+3]]:20: portability: #include: extra stuff ignored after file name
16 ! CHECK: prescanner-diag.f90:[[#@LINE+3]]:20: portability: #include: extra stuff ignored after file name
18 #include <empty.h> comment
19 #include "empty.h" comment
20 end