flang/test/Driver/parse-ir-error.f95
raw| 1 | ! This file is a valid Fortran file, but we force the driver to treat it as an |
| 2 | ! LLVM file (with the `-x` flag). This way we verify that the driver correctly |
| 3 | ! rejects invalid LLVM IR input. |
| 4 | |
| 5 | ! Input type is implicit (correctly assumed to be Fortran) |
| 6 | ! RUN: %flang_fc1 -S -o /dev/null %s |
| 7 | ! Input type is explicitly set as LLVM IR |
| 8 | ! RUN: not %flang -S -x ir %s 2>&1 | FileCheck %s |
| 9 | |
| 10 | ! CHECK: error: Could not parse IR |
| 11 | |
| 12 | end program |