1 
2 #define import @import
3 import lookup_left_cxx;
4 #undef import
5 #define IMPORT(X) @import X
6 IMPORT(lookup_right_cxx);
7 
8 void test(int i, float f) {
9   // unqualified lookup
10   f0(&i);
11   f0(&f);
12 
13   // qualified lookup into the translation unit
14   ::f0(&i);
15   ::f0(&f);
16 }
17 
18 int import;
19 
20 void f() {
21  int import;
22 }
23 
24 // RUN: rm -rf %t
25 // RUN: %clang_cc1 -fmodules -x objective-c++ -emit-module -fmodule-cache-path %t -fmodule-name=lookup_left_cxx %S/Inputs/module.map -verify
26 // RUN: %clang_cc1 -fmodules -x objective-c++ -emit-module -fmodule-cache-path %t -fmodule-name=lookup_right_cxx %S/Inputs/module.map -verify
27 // RUN: %clang_cc1 -fmodules -x objective-c++ -fmodule-cache-path %t %s -verify
28 // RUN: %clang_cc1 -fmodules -ast-print -x objective-c++ -fmodule-cache-path %t %s | FileCheck -check-prefix=CHECK-PRINT %s
29 // FIXME: When we have a syntax for modules in C++, use that.
30 
31 // CHECK-PRINT: int *f0(int *);
32 // CHECK-PRINT: float *f0(float *);
33 // CHECK-PRINT: void test(int i, float f)
34 
35