2012-12-01 02:38:50 +08:00
|
|
|
// RUN: rm -rf %t
|
2015-06-16 08:08:24 +08:00
|
|
|
// RUN: not %clang_cc1 -fmodules-cache-path=%t -fmodules -fimplicit-module-maps -F %S/Inputs -DgetModuleVersion="epic fail" %s 2>&1 | FileCheck %s
|
2012-12-01 02:38:50 +08:00
|
|
|
|
2012-12-12 06:11:52 +08:00
|
|
|
@import DependsOnModule;
|
2012-12-01 02:38:50 +08:00
|
|
|
|
|
|
|
// CHECK: While building module 'DependsOnModule' imported from
|
|
|
|
// CHECK: While building module 'Module' imported from
|
|
|
|
// CHECK: error: expected ';' after top level declarator
|
2012-12-06 06:18:04 +08:00
|
|
|
// CHECK: note: expanded from here
|
2012-12-01 02:38:50 +08:00
|
|
|
// CHECK: fatal error: could not build module 'Module'
|
|
|
|
// CHECK: fatal error: could not build module 'DependsOnModule'
|
|
|
|
// CHECK-NOT: error:
|
2012-12-01 05:58:49 +08:00
|
|
|
|
2015-06-16 08:08:24 +08:00
|
|
|
// RUN: not %clang_cc1 -fmodules-cache-path=%t -fmodules -fimplicit-module-maps -F %S/Inputs %s -fdiagnostics-show-note-include-stack 2>&1 | FileCheck -check-prefix=CHECK-REDEF %s
|
2012-12-01 05:58:49 +08:00
|
|
|
extern int Module;
|
|
|
|
|
|
|
|
// CHECK-REDEF: In module 'DependsOnModule' imported from
|
|
|
|
// CHECK-REDEF: In module 'Module' imported from
|
|
|
|
// CHECK-REDEF: Module.h:15:12: note: previous definition is here
|
2012-12-01 07:32:31 +08:00
|
|
|
|
2015-06-16 08:08:24 +08:00
|
|
|
// RUN: not %clang_cc1 -Wincomplete-umbrella -fmodules-cache-path=%t -fmodules -fimplicit-module-maps -F %S/Inputs -DgetModuleVersion="epic fail" -serialize-diagnostic-file %t/tmp.diag %s 2>&1
|
2012-12-06 06:18:04 +08:00
|
|
|
// RUN: c-index-test -read-diagnostics %t/tmp.diag 2>&1 | FileCheck -check-prefix=CHECK-SDIAG %s
|
2012-12-01 07:32:31 +08:00
|
|
|
|
2012-12-01 07:40:49 +08:00
|
|
|
// CHECK-SDIAG: Module.h:9:13: error: expected ';' after top level declarator
|
2012-12-12 06:11:52 +08:00
|
|
|
// CHECK-SDIAG: build-fail-notes.m:4:9: note: while building module 'DependsOnModule' imported from
|
2012-12-01 07:40:49 +08:00
|
|
|
// CHECK-SDIAG: DependsOnModule.h:1:10: note: while building module 'Module' imported from
|
2012-12-06 06:18:04 +08:00
|
|
|
// CHECK-SDIAG: note: expanded from here
|
2013-01-05 02:58:28 +08:00
|
|
|
// CHECK-SDIAG: warning: umbrella header for module 'Module' does not include header 'NotInModule.h' [-Wincomplete-umbrella]
|
2012-12-01 07:40:49 +08:00
|
|
|
// CHECK-SDIAG: DependsOnModule.h:1:10: fatal: could not build module 'Module'
|
2012-12-12 06:11:52 +08:00
|
|
|
// CHECK-SDIAG: build-fail-notes.m:4:9: note: while building module 'DependsOnModule' imported from
|
2012-12-01 07:32:31 +08:00
|
|
|
|