p11.cpp revision 29ae6e5fb001deddd831e66faf143ecd9e50f67c
1// RUN: %clang_cc1 -fsyntax-only -verify %s
2
3// rdar://problem/8540720
4namespace test0 {
5  void foo() {
6    void bar();
7    class A {
8      friend void bar();
9    };
10  }
11}
12
13namespace test1 {
14  void foo() {
15    class A {
16      friend void bar(); // expected-error {{no matching function found in local scope}}
17    };
18  }
19}
20