Richard Smith | 0414b85 | 2015-02-14 05:32:00 +0000 | [diff] [blame^] | 1 | // RUN: %clang_cc1 -fmodules -fmodules-cache-path=%t -fmodule-map-file=%s -fsyntax-only -x c++ /dev/null 2>&1 |
| 2 | // |
Richard Smith | ac425e9 | 2015-01-23 00:01:13 +0000 | [diff] [blame] | 3 | // RUN: cp %s %t-duplicate.modulemap |
| 4 | // RUN: not %clang_cc1 -fmodules -fmodules-cache-path=%t -fmodule-map-file=%s -fmodule-map-file=%t-duplicate.modulemap -fsyntax-only -x c++ /dev/null 2>&1 | FileCheck --check-prefix=CHECK-DUPLICATE %s |
| 5 | |
| 6 | // PR22299: Ensure we can produce diagnostics for duplicate modules from -fmodule-map-file=. |
| 7 | // |
| 8 | // CHECK-DUPLICATE: duplicate.modulemap:[[@LINE+2]]:8: error: redefinition of module 'foo' |
| 9 | // CHECK-DUPLICATE: diagnostics.modulemap:[[@LINE+1]]:8: note: previously defined here |
| 10 | module foo {} |
Richard Smith | 0414b85 | 2015-02-14 05:32:00 +0000 | [diff] [blame^] | 11 | |
| 12 | //* Check that we accept BCPL comments properly, not just as an extension. */ |