diff --git a/flang/test/Evaluate/test_folding.sh b/flang/test/Evaluate/test_folding.sh --- a/flang/test/Evaluate/test_folding.sh +++ b/flang/test/Evaluate/test_folding.sh @@ -32,7 +32,7 @@ mkdir -p $temp shift -CMD="$* -fdebug-dump-symbols -fparse-only" +CMD="$* -fdebug-dump-symbols -fsyntax-only" # Check if tests should assume folding is using libpgmath if [[ $LIBPGMATH ]]; then diff --git a/flang/test/Flang-Driver/parse-error.f95 b/flang/test/Flang-Driver/parse-error.f95 --- a/flang/test/Flang-Driver/parse-error.f95 +++ b/flang/test/Flang-Driver/parse-error.f95 @@ -1,5 +1,5 @@ ! RUN: not %flang-new -fc1 -fsyntax-only %s 2>&1 | FileCheck %s --check-prefix=ERROR -! RUN: not %f18 -parse-only %s 2>&1 | FileCheck %s --check-prefix=ERROR +! RUN: not %f18 -fsyntax-only %s 2>&1 | FileCheck %s --check-prefix=ERROR ! REQUIRES: new-flang-driver diff --git a/flang/test/Flang-Driver/syntax-only.f90 b/flang/test/Flang-Driver/syntax-only.f90 --- a/flang/test/Flang-Driver/syntax-only.f90 +++ b/flang/test/Flang-Driver/syntax-only.f90 @@ -1,5 +1,5 @@ ! RUN: not %flang-new -fc1 -fsyntax-only %s 2>&1 | FileCheck %s -! RUN: not %f18 -fparse-only %s 2>&1 | FileCheck %s +! RUN: not %f18 -fsyntax-only %s 2>&1 | FileCheck %s ! REQUIRES: new-flang-driver diff --git a/flang/test/Frontend/prescanner-diag.f90 b/flang/test/Frontend/prescanner-diag.f90 --- a/flang/test/Frontend/prescanner-diag.f90 +++ b/flang/test/Frontend/prescanner-diag.f90 @@ -6,7 +6,7 @@ ! RUN: %flang-new -fc1 -E -I %S/Inputs/ %s 2>&1 | FileCheck %s ! Test with -fsyntax-only (i.e. ParseSyntaxOnlyAction, stops after semantic checks) -! RUN: %f18 -fparse-only -I %S/Inputs/ %s 2>&1 | FileCheck %s +! RUN: %f18 -fsyntax-only -I %S/Inputs/ %s 2>&1 | FileCheck %s ! RUN: %flang-new -fsyntax-only -I %S/Inputs/ %s 2>&1 | FileCheck %s ! RUN: %flang-new -fc1 -fsyntax-only -I %S/Inputs/ %s 2>&1 | FileCheck %s diff --git a/flang/test/Lower/pre-fir-tree01.f90 b/flang/test/Lower/pre-fir-tree01.f90 --- a/flang/test/Lower/pre-fir-tree01.f90 +++ b/flang/test/Lower/pre-fir-tree01.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fdebug-pre-fir-tree -fparse-only %s | FileCheck %s +! RUN: %f18 -fdebug-pre-fir-tree -fsyntax-only %s | FileCheck %s ! Test structure of the Pre-FIR tree diff --git a/flang/test/Lower/pre-fir-tree02.f90 b/flang/test/Lower/pre-fir-tree02.f90 --- a/flang/test/Lower/pre-fir-tree02.f90 +++ b/flang/test/Lower/pre-fir-tree02.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fdebug-pre-fir-tree -fparse-only %s | FileCheck %s +! RUN: %f18 -fdebug-pre-fir-tree -fsyntax-only %s | FileCheck %s ! Test Pre-FIR Tree captures all the intended nodes from the parse-tree ! Coarray and OpenMP related nodes are tested in other files. diff --git a/flang/test/Lower/pre-fir-tree03.f90 b/flang/test/Lower/pre-fir-tree03.f90 --- a/flang/test/Lower/pre-fir-tree03.f90 +++ b/flang/test/Lower/pre-fir-tree03.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fdebug-pre-fir-tree -fparse-only -fopenmp %s | FileCheck %s +! RUN: %f18 -fdebug-pre-fir-tree -fsyntax-only -fopenmp %s | FileCheck %s ! Test Pre-FIR Tree captures OpenMP related constructs diff --git a/flang/test/Lower/pre-fir-tree04.f90 b/flang/test/Lower/pre-fir-tree04.f90 --- a/flang/test/Lower/pre-fir-tree04.f90 +++ b/flang/test/Lower/pre-fir-tree04.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fdebug-pre-fir-tree -fparse-only %s | FileCheck %s +! RUN: %f18 -fdebug-pre-fir-tree -fsyntax-only %s | FileCheck %s ! Test Pre-FIR Tree captures all the coarray related statements diff --git a/flang/test/Lower/pre-fir-tree05.f90 b/flang/test/Lower/pre-fir-tree05.f90 --- a/flang/test/Lower/pre-fir-tree05.f90 +++ b/flang/test/Lower/pre-fir-tree05.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fdebug-pre-fir-tree -fparse-only -fopenacc %s | FileCheck %s +! RUN: %f18 -fdebug-pre-fir-tree -fsyntax-only -fopenacc %s | FileCheck %s ! Test structure of the Pre-FIR tree with OpenACC construct diff --git a/flang/test/Semantics/call17.f90 b/flang/test/Semantics/call17.f90 --- a/flang/test/Semantics/call17.f90 +++ b/flang/test/Semantics/call17.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fparse-only $s 2>&1 | FileCheck %s +! RUN: %f18 -fsyntax-only $s 2>&1 | FileCheck %s ! Regression test: don't emit a bogus error about an invalid specification expression ! in the declaration of a binding diff --git a/flang/test/Semantics/data05.f90 b/flang/test/Semantics/data05.f90 --- a/flang/test/Semantics/data05.f90 +++ b/flang/test/Semantics/data05.f90 @@ -1,4 +1,4 @@ -!RUN: %f18 -fdebug-dump-symbols -fparse-only %s | FileCheck %s +!RUN: %f18 -fdebug-dump-symbols -fsyntax-only %s | FileCheck %s module m interface integer function ifunc(n) diff --git a/flang/test/Semantics/data08.f90 b/flang/test/Semantics/data08.f90 --- a/flang/test/Semantics/data08.f90 +++ b/flang/test/Semantics/data08.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fdebug-dump-symbols -fparse-only %s 2>&1 | FileCheck %s +! RUN: %f18 -fdebug-dump-symbols -fsyntax-only %s 2>&1 | FileCheck %s ! CHECK: DATA statement value initializes 'jx' of type 'INTEGER(4)' with CHARACTER ! CHECK: DATA statement value initializes 'jy' of type 'INTEGER(4)' with CHARACTER ! CHECK: DATA statement value initializes 'jz' of type 'INTEGER(4)' with CHARACTER diff --git a/flang/test/Semantics/data09.f90 b/flang/test/Semantics/data09.f90 --- a/flang/test/Semantics/data09.f90 +++ b/flang/test/Semantics/data09.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fparse-only -fdebug-dump-symbols %s 2>&1 | FileCheck %s +! RUN: %f18 -fsyntax-only -fdebug-dump-symbols %s 2>&1 | FileCheck %s ! CHECK: init:[INTEGER(4)::1065353216_4,1073741824_4,1077936128_4,1082130432_4] ! Verify that the closure of EQUIVALENCE'd symbols with any DATA ! initialization produces a combined initializer. diff --git a/flang/test/Semantics/empty.f90 b/flang/test/Semantics/empty.f90 --- a/flang/test/Semantics/empty.f90 +++ b/flang/test/Semantics/empty.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fparse-only %s +! RUN: %f18 -fsyntax-only %s ! RUN: rm -rf %t && mkdir %t ! RUN: touch %t/empty.f90 -! RUN: %f18 -fparse-only %t/empty.f90 +! RUN: %f18 -fsyntax-only %t/empty.f90 diff --git a/flang/test/Semantics/final02.f90 b/flang/test/Semantics/final02.f90 --- a/flang/test/Semantics/final02.f90 +++ b/flang/test/Semantics/final02.f90 @@ -1,4 +1,4 @@ -!RUN: %f18 -fparse-only %s 2>&1 | FileCheck %s +!RUN: %f18 -fsyntax-only %s 2>&1 | FileCheck %s module m type :: t1 integer :: n diff --git a/flang/test/Semantics/getdefinition01.f90 b/flang/test/Semantics/getdefinition01.f90 --- a/flang/test/Semantics/getdefinition01.f90 +++ b/flang/test/Semantics/getdefinition01.f90 @@ -16,12 +16,12 @@ end module ! RUN and CHECK lines at the bottom as this test is sensitive to line numbers -! RUN: %f18 -fget-definition 6 17 18 -fparse-only %s | FileCheck --check-prefix=CHECK1 %s -! RUN: %f18 -fget-definition 7 20 23 -fparse-only %s | FileCheck --check-prefix=CHECK2 %s -! RUN: %f18 -fget-definition 14 3 4 -fparse-only %s | FileCheck --check-prefix=CHECK3 %s +! RUN: %f18 -fget-definition 6 17 18 -fsyntax-only %s | FileCheck --check-prefix=CHECK1 %s +! RUN: %f18 -fget-definition 7 20 23 -fsyntax-only %s | FileCheck --check-prefix=CHECK2 %s +! RUN: %f18 -fget-definition 14 3 4 -fsyntax-only %s | FileCheck --check-prefix=CHECK3 %s ! CHECK1: x:{{.*}}getdefinition01.f90, 5, 21-22 ! CHECK2: yyy:{{.*}}getdefinition01.f90, 5, 24-27 ! CHECK3: x:{{.*}}getdefinition01.f90, 13, 24-25 -! RUN: not %f18 -fget-definition -fparse-only %s 2>&1 | FileCheck --check-prefix=CHECK-ERROR %s +! RUN: not %f18 -fget-definition -fsyntax-only %s 2>&1 | FileCheck --check-prefix=CHECK-ERROR %s ! CHECK-ERROR: Invalid argument to -fget-definitions diff --git a/flang/test/Semantics/getdefinition02.f b/flang/test/Semantics/getdefinition02.f --- a/flang/test/Semantics/getdefinition02.f +++ b/flang/test/Semantics/getdefinition02.f @@ -17,9 +17,9 @@ end module ! RUN and CHECK lines here as test is sensitive to line numbers -! RUN: %f18 -fget-definition 7 9 10 -fparse-only %s 2>&1 | FileCheck --check-prefix=CHECK1 %s -! RUN: %f18 -fget-definition 8 26 29 -fparse-only %s 2>&1 | FileCheck --check-prefix=CHECK2 %s -! RUN: %f18 -fget-definition 15 9 10 -fparse-only %s 2>&1 | FileCheck --check-prefix=CHECK3 %s +! RUN: %f18 -fget-definition 7 9 10 -fsyntax-only %s 2>&1 | FileCheck --check-prefix=CHECK1 %s +! RUN: %f18 -fget-definition 8 26 29 -fsyntax-only %s 2>&1 | FileCheck --check-prefix=CHECK2 %s +! RUN: %f18 -fget-definition 15 9 10 -fsyntax-only %s 2>&1 | FileCheck --check-prefix=CHECK3 %s ! CHECK1: x:{{.*}}getdefinition02.f, 5, 27-28 ! CHECK2: yyy:{{.*}}getdefinition02.f, 5, 30-33 ! CHECK3: x:{{.*}}getdefinition02.f, 14, 30-31 diff --git a/flang/test/Semantics/getdefinition03-a.f90 b/flang/test/Semantics/getdefinition03-a.f90 --- a/flang/test/Semantics/getdefinition03-a.f90 +++ b/flang/test/Semantics/getdefinition03-a.f90 @@ -7,7 +7,7 @@ x = f end program -! RUN: %f18 -fget-definition 7 6 7 -fparse-only %s | FileCheck --check-prefix=CHECK1 %s -! RUN: %f18 -fget-definition 7 2 3 -fparse-only %s | FileCheck --check-prefix=CHECK2 %s +! RUN: %f18 -fget-definition 7 6 7 -fsyntax-only %s | FileCheck --check-prefix=CHECK1 %s +! RUN: %f18 -fget-definition 7 2 3 -fsyntax-only %s | FileCheck --check-prefix=CHECK2 %s ! CHECK1: f:{{.*}}getdefinition03-b.f90, 2, 12-13 ! CHECK2: x:{{.*}}getdefinition03-a.f90, 6, 13-14 diff --git a/flang/test/Semantics/getdefinition04.f90 b/flang/test/Semantics/getdefinition04.f90 --- a/flang/test/Semantics/getdefinition04.f90 +++ b/flang/test/Semantics/getdefinition04.f90 @@ -6,5 +6,5 @@ x = y end program -! RUN: %f18 -fget-definition 6 3 4 -fparse-only %s | FileCheck %s +! RUN: %f18 -fget-definition 6 3 4 -fsyntax-only %s | FileCheck %s ! CHECK: x:{{.*}}getdefinition04.f90, 3, 14-15 diff --git a/flang/test/Semantics/getdefinition05.f90 b/flang/test/Semantics/getdefinition05.f90 --- a/flang/test/Semantics/getdefinition05.f90 +++ b/flang/test/Semantics/getdefinition05.f90 @@ -12,8 +12,8 @@ end program !! Inner x -! RUN: %f18 -fget-definition 9 5 6 -fparse-only %s | FileCheck --check-prefix=CHECK1 %s +! RUN: %f18 -fget-definition 9 5 6 -fsyntax-only %s | FileCheck --check-prefix=CHECK1 %s ! CHECK1: x:{{.*}}getdefinition05.f90, 7, 16-17 !! Outer y -! RUN: %f18 -fget-definition 11 7 8 -fparse-only %s | FileCheck --check-prefix=CHECK2 %s +! RUN: %f18 -fget-definition 11 7 8 -fsyntax-only %s | FileCheck --check-prefix=CHECK2 %s ! CHECK2: y:{{.*}}getdefinition05.f90, 5, 14-15 diff --git a/flang/test/Semantics/getsymbols01.f90 b/flang/test/Semantics/getsymbols01.f90 --- a/flang/test/Semantics/getsymbols01.f90 +++ b/flang/test/Semantics/getsymbols01.f90 @@ -15,7 +15,7 @@ end function end module -! RUN: %f18 -fget-symbols-sources -fparse-only %s 2>&1 | FileCheck %s +! RUN: %f18 -fget-symbols-sources -fsyntax-only %s 2>&1 | FileCheck %s ! CHECK-COUNT-1:f:{{.*}}getsymbols01.f90, 12, 26-27 ! CHECK-COUNT-1:mm1:{{.*}}getsymbols01.f90, 2, 8-11 ! CHECK-COUNT-1:s:{{.*}}getsymbols01.f90, 5, 18-19 diff --git a/flang/test/Semantics/getsymbols02.f90 b/flang/test/Semantics/getsymbols02.f90 --- a/flang/test/Semantics/getsymbols02.f90 +++ b/flang/test/Semantics/getsymbols02.f90 @@ -7,8 +7,8 @@ i = callget5() ENDPROGRAM -! RUN: %f18 -fparse-only %S/Inputs/getsymbols02-a.f90 -! RUN: %f18 -fparse-only %S/Inputs/getsymbols02-b.f90 -! RUN: %f18 -fget-symbols-sources -fparse-only %s 2>&1 | FileCheck %s +! RUN: %f18 -fsyntax-only %S/Inputs/getsymbols02-a.f90 +! RUN: %f18 -fsyntax-only %S/Inputs/getsymbols02-b.f90 +! RUN: %f18 -fget-symbols-sources -fsyntax-only %s 2>&1 | FileCheck %s ! CHECK: callget5: .{{[/\\]}}mm2b.mod, ! CHECK: get5: .{{[/\\]}}mm2a.mod, diff --git a/flang/test/Semantics/getsymbols03-a.f90 b/flang/test/Semantics/getsymbols03-a.f90 --- a/flang/test/Semantics/getsymbols03-a.f90 +++ b/flang/test/Semantics/getsymbols03-a.f90 @@ -7,7 +7,7 @@ x = f end program -! RUN: %f18 -fget-symbols-sources -fparse-only %s 2>&1 | FileCheck %s +! RUN: %f18 -fget-symbols-sources -fsyntax-only %s 2>&1 | FileCheck %s ! CHECK:f:{{.*}}getsymbols03-b.f90, 2, 12-13 ! CHECK:main:{{.*}}getsymbols03-a.f90, 4, 9-13 ! CHECK:mm3:{{.*}}getsymbols03-a.f90, 5, 6-9 diff --git a/flang/test/Semantics/getsymbols04.f90 b/flang/test/Semantics/getsymbols04.f90 --- a/flang/test/Semantics/getsymbols04.f90 +++ b/flang/test/Semantics/getsymbols04.f90 @@ -6,7 +6,7 @@ x = y end program -! RUN: %f18 -fget-symbols-sources -fparse-only %s 2>&1 | FileCheck %s +! RUN: %f18 -fget-symbols-sources -fsyntax-only %s 2>&1 | FileCheck %s ! CHECK:x:{{.*}}getsymbols04.f90, 3, 14-15 ! CHECK:x:{{.*}}getsymbols04.f90, 5, 11-12 ! CHECK:y:{{.*}}getsymbols04.f90, 4, 14-15 diff --git a/flang/test/Semantics/getsymbols05.f90 b/flang/test/Semantics/getsymbols05.f90 --- a/flang/test/Semantics/getsymbols05.f90 +++ b/flang/test/Semantics/getsymbols05.f90 @@ -9,7 +9,7 @@ x = y end program -! RUN: %f18 -fget-symbols-sources -fparse-only %s 2>&1 | FileCheck %s +! RUN: %f18 -fget-symbols-sources -fsyntax-only %s 2>&1 | FileCheck %s ! CHECK:x:{{.*}}getsymbols05.f90, 3, 14-15 ! CHECK:x:{{.*}}getsymbols05.f90, 6, 16-17 ! CHECK:y:{{.*}}getsymbols05.f90, 4, 14-15 diff --git a/flang/test/Semantics/missing_newline.f90 b/flang/test/Semantics/missing_newline.f90 --- a/flang/test/Semantics/missing_newline.f90 +++ b/flang/test/Semantics/missing_newline.f90 @@ -1,4 +1,4 @@ ! RUN: echo -n "end program" > %t.f90 -! RUN: %f18 -fparse-only %t.f90 +! RUN: %f18 -fsyntax-only %t.f90 ! RUN: echo -ne "\rend program" > %t.f90 -! RUN: %f18 -fparse-only %t.f90 +! RUN: %f18 -fsyntax-only %t.f90 diff --git a/flang/test/Semantics/mod-file-rewriter.f90 b/flang/test/Semantics/mod-file-rewriter.f90 --- a/flang/test/Semantics/mod-file-rewriter.f90 +++ b/flang/test/Semantics/mod-file-rewriter.f90 @@ -1,8 +1,8 @@ ! RUN: rm -fr %t && mkdir %t && cd %t -! RUN: %f18 -fparse-only -fdebug-module-writer %s 2>&1 | FileCheck %s --check-prefix CHECK_CHANGED -! RUN: %f18 -fparse-only -fdebug-module-writer %s 2>&1 | FileCheck %s --check-prefix CHECK_UNCHANGED -! RUN: %f18 -fparse-only -fdebug-module-writer %p/Inputs/mod-file-unchanged.f90 2>&1 | FileCheck %s --check-prefix CHECK_UNCHANGED -! RUN: %f18 -fparse-only -fdebug-module-writer %p/Inputs/mod-file-changed.f90 2>&1 | FileCheck %s --check-prefix CHECK_CHANGED +! RUN: %f18 -fsyntax-only -fdebug-module-writer %s 2>&1 | FileCheck %s --check-prefix CHECK_CHANGED +! RUN: %f18 -fsyntax-only -fdebug-module-writer %s 2>&1 | FileCheck %s --check-prefix CHECK_UNCHANGED +! RUN: %f18 -fsyntax-only -fdebug-module-writer %p/Inputs/mod-file-unchanged.f90 2>&1 | FileCheck %s --check-prefix CHECK_UNCHANGED +! RUN: %f18 -fsyntax-only -fdebug-module-writer %p/Inputs/mod-file-changed.f90 2>&1 | FileCheck %s --check-prefix CHECK_CHANGED module m real :: x(10) diff --git a/flang/test/Semantics/modifiable01.f90 b/flang/test/Semantics/modifiable01.f90 --- a/flang/test/Semantics/modifiable01.f90 +++ b/flang/test/Semantics/modifiable01.f90 @@ -1,4 +1,4 @@ -! RUN: not %f18 -fparse-only %s 2>&1 | FileCheck %s +! RUN: not %f18 -fsyntax-only %s 2>&1 | FileCheck %s ! Test WhyNotModifiable() explanations module prot diff --git a/flang/test/Semantics/offsets01.f90 b/flang/test/Semantics/offsets01.f90 --- a/flang/test/Semantics/offsets01.f90 +++ b/flang/test/Semantics/offsets01.f90 @@ -1,4 +1,4 @@ -!RUN: %f18 -fdebug-dump-symbols -fparse-only %s | FileCheck %s +!RUN: %f18 -fdebug-dump-symbols -fsyntax-only %s | FileCheck %s ! Size and alignment of intrinsic types subroutine s1 diff --git a/flang/test/Semantics/offsets02.f90 b/flang/test/Semantics/offsets02.f90 --- a/flang/test/Semantics/offsets02.f90 +++ b/flang/test/Semantics/offsets02.f90 @@ -1,4 +1,4 @@ -!RUN: %f18 -fdebug-dump-symbols -fparse-only %s | FileCheck %s +!RUN: %f18 -fdebug-dump-symbols -fsyntax-only %s | FileCheck %s ! Size and alignment of derived types diff --git a/flang/test/Semantics/offsets03.f90 b/flang/test/Semantics/offsets03.f90 --- a/flang/test/Semantics/offsets03.f90 +++ b/flang/test/Semantics/offsets03.f90 @@ -1,4 +1,4 @@ -!RUN: %f18 -fdebug-dump-symbols -fparse-only %s | FileCheck %s +!RUN: %f18 -fdebug-dump-symbols -fsyntax-only %s | FileCheck %s ! Size and alignment with EQUIVALENCE and COMMON diff --git a/flang/test/Semantics/oldparam01.f90 b/flang/test/Semantics/oldparam01.f90 --- a/flang/test/Semantics/oldparam01.f90 +++ b/flang/test/Semantics/oldparam01.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -falternative-parameter-statement -fdebug-dump-symbols -fparse-only %s 2>&1 | FileCheck %s +! RUN: %f18 -falternative-parameter-statement -fdebug-dump-symbols -fsyntax-only %s 2>&1 | FileCheck %s ! Non-error tests for "old style" PARAMETER statements diff --git a/flang/test/Semantics/oldparam02.f90 b/flang/test/Semantics/oldparam02.f90 --- a/flang/test/Semantics/oldparam02.f90 +++ b/flang/test/Semantics/oldparam02.f90 @@ -1,4 +1,4 @@ -! RUN: not %f18 -falternative-parameter-statement -fdebug-dump-symbols -fparse-only %s 2>&1 | FileCheck %s +! RUN: not %f18 -falternative-parameter-statement -fdebug-dump-symbols -fsyntax-only %s 2>&1 | FileCheck %s ! Error tests for "old style" PARAMETER statements subroutine subr(x1,x2,x3,x4,x5) diff --git a/flang/test/Semantics/oldparam03.f90 b/flang/test/Semantics/oldparam03.f90 --- a/flang/test/Semantics/oldparam03.f90 +++ b/flang/test/Semantics/oldparam03.f90 @@ -1,4 +1,4 @@ -! RUN: not %f18 -fparse-only %s 2>&1 | FileCheck %s +! RUN: not %f18 -fsyntax-only %s 2>&1 | FileCheck %s ! Ensure that old-style PARAMETER statements are disabled by default. diff --git a/flang/test/Semantics/resolve100.f90 b/flang/test/Semantics/resolve100.f90 --- a/flang/test/Semantics/resolve100.f90 +++ b/flang/test/Semantics/resolve100.f90 @@ -1,4 +1,4 @@ -!RUN: %f18 -fdebug-dump-symbols -fparse-only %s | FileCheck %s +!RUN: %f18 -fdebug-dump-symbols -fsyntax-only %s | FileCheck %s program p ! CHECK: a size=4 offset=0: ObjectEntity type: LOGICAL(4) diff --git a/flang/test/Semantics/rewrite01.f90 b/flang/test/Semantics/rewrite01.f90 --- a/flang/test/Semantics/rewrite01.f90 +++ b/flang/test/Semantics/rewrite01.f90 @@ -1,4 +1,4 @@ -! RUN: %f18 -fparse-only -fdebug-dump-parse-tree %s 2>&1 | FileCheck %s +! RUN: %f18 -fsyntax-only -fdebug-dump-parse-tree %s 2>&1 | FileCheck %s ! Ensure that READ(CVAR) [, item-list] is corrected when CVAR is a ! character variable so as to be a formatted read from the default ! unit, not an unformatted read from an internal unit (which is not diff --git a/flang/test/Semantics/test_errors.sh b/flang/test/Semantics/test_errors.sh --- a/flang/test/Semantics/test_errors.sh +++ b/flang/test/Semantics/test_errors.sh @@ -2,7 +2,7 @@ # Compile a source file and check errors against those listed in the file. # Change the compiler by setting the F18 environment variable. -F18_OPTIONS="-fparse-only" +F18_OPTIONS="-fsyntax-only" srcdir=$(dirname $0) source $srcdir/common.sh [[ ! -f $src ]] && die "File not found: $src" diff --git a/flang/test/Semantics/test_modfile.sh b/flang/test/Semantics/test_modfile.sh --- a/flang/test/Semantics/test_modfile.sh +++ b/flang/test/Semantics/test_modfile.sh @@ -2,7 +2,7 @@ # Compile a source file and compare generated .mod files against expected. set -e -F18_OPTIONS="-fdebug-resolve-names -fparse-only" +F18_OPTIONS="-fdebug-resolve-names -fsyntax-only" srcdir=$(dirname $0) source $srcdir/common.sh diff --git a/flang/test/Semantics/typeinfo01.f90 b/flang/test/Semantics/typeinfo01.f90 --- a/flang/test/Semantics/typeinfo01.f90 +++ b/flang/test/Semantics/typeinfo01.f90 @@ -1,4 +1,4 @@ -!RUN: %f18 -fdebug-dump-symbols -fparse-only %s | FileCheck %s +!RUN: %f18 -fdebug-dump-symbols -fsyntax-only %s | FileCheck %s ! Tests for derived type runtime descriptions module m01 diff --git a/flang/tools/f18/f18.cpp b/flang/tools/f18/f18.cpp --- a/flang/tools/f18/f18.cpp +++ b/flang/tools/f18/f18.cpp @@ -92,7 +92,7 @@ bool warningsAreErrors{false}; // -Werror bool byteswapio{false}; // -byteswapio Fortran::parser::Encoding encoding{Fortran::parser::Encoding::UTF_8}; - bool parseOnly{false}; + bool syntaxOnly{false}; bool dumpProvenance{false}; bool dumpCookedChars{false}; bool dumpUnparse{false}; @@ -327,7 +327,7 @@ exitStatus = EXIT_FAILURE; } } - if (driver.parseOnly) { + if (driver.syntaxOnly) { return {}; } @@ -544,8 +544,13 @@ driver.dumpUnparseWithSymbols = true; } else if (arg == "-funparse-typed-exprs-to-f18-fc") { driver.unparseTypedExprsToF18_FC = true; + } else if (arg == "-fsyntax-only") { + driver.syntaxOnly = true; } else if (arg == "-fparse-only") { - driver.parseOnly = true; + driver.syntaxOnly = true; + llvm::outs() << "warnning: `-fparse-only` is deprecated and will " + "be removed in the future, use `-fsyntax-only` " + "instead \n"; } else if (arg == "-c") { driver.compileOnly = true; } else if (arg == "-o") {