blob: ca12a281af8ee5080d43014abb8f7aaffda2c893 [file] [log] [blame]
Douglas Gregor94619c82011-08-24 19:03:07 +00001
2void test(int i, float f) {
3 // unqualified lookup
4 f0(&i);
5 f0(&f);
6
7 // qualified lookup into the translation unit
8 ::f0(&i);
9 ::f0(&f);
10}
11
Douglas Gregor1257f972011-08-24 21:27:34 +000012// RUN: %clang_cc1 -emit-pch -x c++ -o %t_lookup_left.h.pch %S/Inputs/lookup_left.hpp
13// RUN: %clang_cc1 -emit-pch -x c++ -o %t_lookup_right.h.pch %S/Inputs/lookup_right.hpp
14// RUN: %clang_cc1 -x c++ -import-module %t_lookup_left.h.pch -import-module %t_lookup_right.h.pch -verify %s
15// RUN: %clang_cc1 -ast-print -x c++ -import-module %t_lookup_left.h.pch -import-module %t_lookup_right.h.pch %s | FileCheck -check-prefix=CHECK-PRINT %s
16
17// CHECK-PRINT: int *f0(int *);
18// CHECK-PRINT: float *f0(float *);
19// CHECK-PRINT: void test(int i, float f)
20