summaryrefslogtreecommitdiff
path: root/test/Modules/Inputs/codegen-opt
diff options
context:
space:
mode:
Diffstat (limited to 'test/Modules/Inputs/codegen-opt')
-rw-r--r--test/Modules/Inputs/codegen-opt/bar.h2
-rw-r--r--test/Modules/Inputs/codegen-opt/bar.modulemap1
-rw-r--r--test/Modules/Inputs/codegen-opt/foo.h10
-rw-r--r--test/Modules/Inputs/codegen-opt/foo.modulemap1
-rw-r--r--test/Modules/Inputs/codegen-opt/use.cpp2
5 files changed, 16 insertions, 0 deletions
diff --git a/test/Modules/Inputs/codegen-opt/bar.h b/test/Modules/Inputs/codegen-opt/bar.h
new file mode 100644
index 000000000000..a00e8f70e089
--- /dev/null
+++ b/test/Modules/Inputs/codegen-opt/bar.h
@@ -0,0 +1,2 @@
+#include "foo.h"
+inline void bar() { foo(); }
diff --git a/test/Modules/Inputs/codegen-opt/bar.modulemap b/test/Modules/Inputs/codegen-opt/bar.modulemap
new file mode 100644
index 000000000000..f1dc625857e0
--- /dev/null
+++ b/test/Modules/Inputs/codegen-opt/bar.modulemap
@@ -0,0 +1 @@
+module bar { header "bar.h" }
diff --git a/test/Modules/Inputs/codegen-opt/foo.h b/test/Modules/Inputs/codegen-opt/foo.h
new file mode 100644
index 000000000000..b3a7af7c9d9b
--- /dev/null
+++ b/test/Modules/Inputs/codegen-opt/foo.h
@@ -0,0 +1,10 @@
+void f1(int &);
+static void f2() {}
+inline void foo() {
+ static int i;
+ f1(i);
+ f2();
+}
+inline void foo2() {
+}
+void foo_ext() {}
diff --git a/test/Modules/Inputs/codegen-opt/foo.modulemap b/test/Modules/Inputs/codegen-opt/foo.modulemap
new file mode 100644
index 000000000000..2e095d2794c3
--- /dev/null
+++ b/test/Modules/Inputs/codegen-opt/foo.modulemap
@@ -0,0 +1 @@
+module foo { header "foo.h" }
diff --git a/test/Modules/Inputs/codegen-opt/use.cpp b/test/Modules/Inputs/codegen-opt/use.cpp
new file mode 100644
index 000000000000..b55a31fe158f
--- /dev/null
+++ b/test/Modules/Inputs/codegen-opt/use.cpp
@@ -0,0 +1,2 @@
+#include "bar.h"
+int main() { bar(); }