blob: 187e8763ca6398e100c007e46b6b9c18bebec9fe [file] [log] [blame]
Douglas Gregor14325692011-11-16 00:21:54 +00001// RUN: rm -rf %t
Douglas Gregor953a61f2013-02-07 19:01:24 +00002// RUN: %clang_cc1 -fmodules -fmodules-cache-path=%t -emit-module -x objective-c -fmodule-name=lookup_left_objc %S/Inputs/module.map
3// RUN: %clang_cc1 -fmodules -fmodules-cache-path=%t -emit-module -x objective-c -fmodule-name=lookup_right_objc %S/Inputs/module.map
Stephen Hines651f13c2014-04-23 16:59:28 -07004// RUN: %clang_cc1 -fmodules -x objective-c -fmodules-cache-path=%t -I %S/Inputs -verify %s
5// RUN: %clang_cc1 -fmodules -ast-print -x objective-c -fmodules-cache-path=%t -I %S/Inputs %s | FileCheck -check-prefix=CHECK-PRINT %s
Douglas Gregor3d15ab82011-08-25 14:51:20 +00006
Andy Gibbsb42f2002013-04-17 08:06:46 +00007@import lookup_left_objc;
8@import lookup_right_objc;
9
10void test(id x) {
11 [x method];
12// expected-warning@-1{{multiple methods named 'method' found}}
13// expected-note@Inputs/lookup_left.h:2{{using}}
14// expected-note@Inputs/lookup_right.h:3{{also found}}
15}
16
Douglas Gregor3d15ab82011-08-25 14:51:20 +000017// CHECK-PRINT: - (int) method;
18// CHECK-PRINT: - (double) method
19// CHECK-PRINT: void test(id x)
20