summaryrefslogtreecommitdiff
path: root/clang/test/CXX/class.access/class.friend/p11.cpp
blob: a05b2d28751e53f1cd7323bb631d0d44424eebc5 (about) (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// RUN: %clang_cc1 -fsyntax-only -verify %s

// rdar://problem/8540720
namespace test0 {
  void foo() {
    void bar();
    class A {
      friend void bar();
    };
  }
}

namespace test1 {
  void foo() {
    class A {
      friend void bar(); // expected-error {{no matching function found in local scope}}
    };
  }
}