aboutsummaryrefslogtreecommitdiff
path: root/test/CXX/basic/basic.lookup/basic.lookup.unqual/p3.cpp
blob: 7fd1b53c2cb0e0d900f5b2b5bb8537f08cbab0db (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// RUN: clang-cc -fsyntax-only -verify %s

typedef int f; 

namespace N0 {
  struct A { 
    friend void f(); 
    void g() {
      int i = f(1);
    }
  };
}

namespace N1 {
  struct A { 
    friend void f(A &);
    operator int();
    void g(A a) {
      // ADL should not apply to the lookup of 'f', it refers to the typedef
      // above.
      int i = f(a);
    }
  };
}