• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// RUN: %clang_cc1 -x objective-c++ -std=c++11 -fsyntax-only -Werror -verify -Wno-objc-root-class %s
2// expected-no-diagnostics
3// rdar://10387088
4
5struct X {
6X();
7void SortWithCollator();
8};
9
10@interface MyClass
11- (void)someMethod;
12@end
13
14@implementation MyClass
15- (void)someMethod {
16    [self privateMethod];  // clang already does not warn here
17}
18
19int bar(MyClass * myObject) {
20    [myObject privateMethod];
21    return gorfbar(myObject);
22}
23- (void)privateMethod { }
24
25int gorfbar(MyClass * myObject) {
26    [myObject privateMethod];
27    [myObject privateMethod1];
28    return getMe + bar(myObject);
29}
30
31- (void)privateMethod1 {
32  getMe = getMe+1;
33}
34
35static int getMe;
36
37static int test() {
38  return 0;
39}
40
41int x{17};
42
43X::X() = default;
44void X::SortWithCollator() {}
45// pr13418
46namespace {
47     int CurrentTabId() {return 0;}
48}
49@end
50