1 ! Checks that the module file:
3 ! * is saved in the _directory specified by the user_
4 ! We use `-fsyntax-only` as it stops after the semantic checks (the module file is generated when sema checks are run)
6 !--------------------------
8 !--------------------------
9 ! RUN: rm -rf %t && mkdir -p %t/dir-flang
10 ! RUN: cd %t && %flang -fsyntax-only -module-dir %t/dir-flang %s
11 ! RUN: ls %t/dir-flang/testmodule.mod && not ls %t/testmodule.mod
14 !--------------------------
16 !--------------------------
17 ! RUN: rm -rf %t && mkdir -p %t/dir-flang
18 ! RUN: cd %t && %flang -fsyntax-only -module-dir%t/dir-flang %s
19 ! RUN: ls %t/dir-flang/testmodule.mod && not ls %t/testmodule.mod
22 !---------------------------
24 !---------------------------
25 ! RUN: rm -rf %t && mkdir -p %t/dir-flang
26 ! RUN: cd %t && %flang -fsyntax-only -J %t/dir-flang %s
27 ! RUN: ls %t/dir-flang/testmodule.mod && not ls %t/testmodule.mod
30 !------------------------------
32 !------------------------------
33 ! RUN: rm -rf %t && mkdir -p %t/dir-flang
34 ! RUN: cd %t && %flang -fsyntax-only -J%t/dir-flang %s
35 ! RUN: ls %t/dir-flang/testmodule.mod && not ls %t/testmodule.mod