r220449 - Test files I forgot to svn add in r220448.
Richard Smith
richard-llvm at metafoo.co.uk
Wed Oct 22 16:52:04 PDT 2014
Author: rsmith
Date: Wed Oct 22 18:52:04 2014
New Revision: 220449
URL: http://llvm.org/viewvc/llvm-project?rev=220449&view=rev
Log:
Test files I forgot to svn add in r220448.
Added:
cfe/trunk/test/Modules/Inputs/declare-use/k.h
cfe/trunk/test/Modules/Inputs/declare-use/l.h
cfe/trunk/test/Modules/textual-headers.cpp
Added: cfe/trunk/test/Modules/Inputs/declare-use/k.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Modules/Inputs/declare-use/k.h?rev=220449&view=auto
==============================================================================
--- cfe/trunk/test/Modules/Inputs/declare-use/k.h (added)
+++ cfe/trunk/test/Modules/Inputs/declare-use/k.h Wed Oct 22 18:52:04 2014
@@ -0,0 +1,8 @@
+#ifdef GIMME_A_K
+
+#ifndef K_H
+#define K_H
+const int k = 42;
+#endif
+
+#endif
Added: cfe/trunk/test/Modules/Inputs/declare-use/l.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Modules/Inputs/declare-use/l.h?rev=220449&view=auto
==============================================================================
--- cfe/trunk/test/Modules/Inputs/declare-use/l.h (added)
+++ cfe/trunk/test/Modules/Inputs/declare-use/l.h Wed Oct 22 18:52:04 2014
@@ -0,0 +1,8 @@
+#ifdef GIMME_AN_L
+
+#ifndef L_H
+#define L_H
+const int l = 42;
+#endif
+
+#endif
Added: cfe/trunk/test/Modules/textual-headers.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Modules/textual-headers.cpp?rev=220449&view=auto
==============================================================================
--- cfe/trunk/test/Modules/textual-headers.cpp (added)
+++ cfe/trunk/test/Modules/textual-headers.cpp Wed Oct 22 18:52:04 2014
@@ -0,0 +1,11 @@
+// RUN: rm -rf %t
+// RUN: %clang_cc1 -fmodule-maps -fmodules-cache-path=%t -fmodules-strict-decluse -fmodule-name=XG -I %S/Inputs/declare-use %s -verify
+// RUN: %clang_cc1 -fmodules -fmodules-cache-path=%t -fmodules-strict-decluse -fmodule-name=XG -I %S/Inputs/declare-use %s -verify
+
+#define GIMME_A_K
+#include "k.h"
+
+#define GIMME_AN_L
+#include "l.h" // expected-error {{module XG does not depend on a module exporting 'l.h'}}
+
+const int g = k + l;
More information about the cfe-commits
mailing list