summaryrefslogtreecommitdiffstats
path: root/clang/test/Modules/declare-use3.cpp
diff options
context:
space:
mode:
authorManuel Klimek <klimek@google.com>2014-03-19 10:22:36 +0000
committerManuel Klimek <klimek@google.com>2014-03-19 10:22:36 +0000
commit98a9a6c6674f0a2aded55a89f6b6d0ef52ab145d (patch)
tree5cc29e021e140238c73c3bb4601782a61febae6d /clang/test/Modules/declare-use3.cpp
parent8e6829e4369832185333a2ce33f599989309b203 (diff)
downloadbcm5719-llvm-98a9a6c6674f0a2aded55a89f6b6d0ef52ab145d.tar.gz
bcm5719-llvm-98a9a6c6674f0a2aded55a89f6b6d0ef52ab145d.zip
Use the expansion location of the file name when finding the module.
The spelling location of stringified strings is not a file location. Optimally, we'll want to solve the problem (as the FIXME states) by handing in the right FileEntry of the #include location. llvm-svn: 204220
Diffstat (limited to 'clang/test/Modules/declare-use3.cpp')
-rw-r--r--clang/test/Modules/declare-use3.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/test/Modules/declare-use3.cpp b/clang/test/Modules/declare-use3.cpp
new file mode 100644
index 00000000000..8b0bbfa756c
--- /dev/null
+++ b/clang/test/Modules/declare-use3.cpp
@@ -0,0 +1,4 @@
+// RUN: rm -rf %t
+// RUN: %clang_cc1 -include "g.h" -include "e.h" -include "f.h" -include "i.h" -fmodule-maps -fmodules-cache-path=%t -fmodules-decluse -fmodule-name=XG -I %S/Inputs/declare-use %s -verify
+// expected-error {{module XG does not depend on a module exporting 'f.h'}}
+const int g2 = g1 + e + f + aux_i;
OpenPOWER on IntegriCloud